Author: Pekka Riikonen <priikone@silcnet.org>
- Copyright (C) 1997 - 2007 Pekka Riikonen
+ Copyright (C) 1997 - 2008 Pekka Riikonen
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
GNU General Public License for more details.
*/
-/* $Id$ */
#include "silc.h"
#include "silcclient.h"
void *callback_context,
void *stream_context)
{
- /* Nothing */
+ SilcClient client = callback_context;
+ SilcClientConnection conn = stream_context;
+
+ /* Read and write errors are silent */
+ if (error == SILC_PACKET_ERR_READ || error == SILC_PACKET_ERR_WRITE)
+ return;
+
+ client->internal->ops->say(client, conn, SILC_CLIENT_MESSAGE_ERROR,
+ (char *)silc_packet_error_string(error));
}
/* Packet stream callbacks */
silc_rng_global_init(client->rng);
/* Initialize the scheduler */
- client->schedule = silc_schedule_init(0, client, NULL);
+ client->schedule = silc_schedule_init(0, client, NULL, NULL);
if (!client->schedule)
return FALSE;