update.
authorPekka Riikonen <priikone@silcnet.org>
Sat, 17 Feb 2001 20:06:31 +0000 (20:06 +0000)
committerPekka Riikonen <priikone@silcnet.org>
Sat, 17 Feb 2001 20:06:31 +0000 (20:06 +0000)
CHANGES
lib/silcclient/client.c

diff --git a/CHANGES b/CHANGES
index 66680e19018b96eb85f502f839eb311d0c0f19ce..f4e6ed1bc52f7f72ea79ad054475cd29e2ff61e0 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -1,3 +1,10 @@
+Sat Feb 17 22:11:50 EET 2001  Pekka Riikonen <priikone@poseidon.pspt.fi>
+
+       * Moved the calling of ops->connect() from connect_to_server_final
+         into receive_new_id functin since that is the point when the
+         client is actually allowed to send traffic to network.  The
+         affected file is lib/silcclient/client.c.
+
 Sat Feb 17 13:15:35 EET 2001  Pekka Riikonen <priikone@poseidon.pspt.fi>
 
        * When receiving NEW_CHANNEL_LIST, NEW_CHANNEL_USER_LIST,
index c19f206ebe43d92ba80f6b68397c5acfb08e92d8..bfb38375b56e19752ec6d3d58660d7fac3be8043 100644 (file)
@@ -496,9 +496,6 @@ SILC_TASK_CALLBACK(silc_client_connect_to_server_final)
   conn->remote_id_data = silc_id_id2str(ctx->dest_id, SILC_ID_SERVER);
   conn->remote_id_data_len = SILC_ID_SERVER_LEN;
 
-  /* Notify application of successful connection */
-  client->ops->connect(client, conn, TRUE);
-
   silc_protocol_free(protocol);
   if (ctx->auth_data)
     silc_free(ctx->auth_data);
@@ -1867,6 +1864,10 @@ void silc_client_receive_new_id(SilcClient client,
   /* Put it to the ID cache */
   silc_idcache_add(conn->client_cache, conn->nickname, SILC_ID_CLIENT,
                   conn->local_id, (void *)conn->local_entry, TRUE);
+
+  /* Notify application of successful connection. We do it here now that
+     we've received the Client ID and are allowed to send traffic. */
+  client->ops->connect(client, conn, TRUE);
 }
 
 /* Processed received Channel ID for a channel. This is called when client