updates.
authorPekka Riikonen <priikone@silcnet.org>
Fri, 22 Jun 2001 12:34:34 +0000 (12:34 +0000)
committerPekka Riikonen <priikone@silcnet.org>
Fri, 22 Jun 2001 12:34:34 +0000 (12:34 +0000)
CHANGES
TODO
apps/irssi/src/silc/core/silc-channels.c

diff --git a/CHANGES b/CHANGES
index 100ce2be1ee9e8a8a6e1d8426cd766fe1e5d2f39..23e98f75082c9384a137f95a24ecc6412497dd04 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -16,6 +16,11 @@ Fri Jun 22 10:44:14 EEST 2001  Pekka Riikonen <priikone@poseidon.pspt.fi>
          They really did not replace the cache entry in the ID Cache.
          Now they do that.  Affected file silcd/idlist.c.
 
+       * Fixed the KICK notify handling in the Irssi SILC client to
+         update the channel records so that the kicked client does not
+         appear to be on the channel.  The affected file is 
+         irssi/src/silc/core/silc-channels.c.
+
 Thu Jun 21 17:10:08 CEST 2001  Pekka Riikonen <priikone@poseidon.pspt.fi>
 
        * Fixed the silc_parse_command_line to remove extra spaces
diff --git a/TODO b/TODO
index 164fe7a005798011e25c8f2836ff58528f59fef0..1e644afd6a9e209b8f8753b2f5bbf40336ce7910 100644 (file)
--- a/TODO
+++ b/TODO
@@ -1,17 +1,6 @@
 TODO/bugs in Irssi SILC client
 ==============================
 
- o LEAVE does not work correctly, it doesn't leave the channel for real!
-
-       o Remove the entire current_channel field from the client
-         library and handle the current channel thingy in the 
-         Irssi SILC client.  Requires short stub functions of all
-         commands that use current current_channel to the Irssi SILC
-         client which then calls the actual library command.
-
- o KILL notify does not remove the killed client from all channels.  The
-   /NAMES will show it still.
-
  o Add PERL scripting support from Irssi CVS.
 
  o Add local commands to list the current server and client public keys
@@ -29,9 +18,6 @@ TODO/bugs in Irssi SILC client
  o Set different kind of settings, like, /set mutual_authentication,
    /set key_exchange_timeout, /set conn_auth_timeout etc etc.
 
- o Do some /set show_mail_notification that would show a notification
-   on screen when new email is received.
-
 
 TODO/bugs In SILC Client Library
 ================================
index 70db4f4f384b4d64a694e9a52e3d36379a7291a8..82d6d08020b5dfc40417820aacc2e81611aaddde 100644 (file)
@@ -420,20 +420,33 @@ static void event_kick(SILC_SERVER_REC *server, va_list va)
   SilcClientEntry client_entry;
   SilcChannelEntry channel_entry;
   char *tmp;
+  SILC_CHANNEL_REC *chanrec;
 
   client_entry = va_arg(va, SilcClientEntry);
   tmp = va_arg(va, char *);
   channel_entry = va_arg(va, SilcChannelEntry);
+
+  chanrec = silc_channel_find_entry(server, channel_entry);
   
   if (client_entry == conn->local_entry) {
     printformat_module("fe-common/silc", server, channel_entry->channel_name,
                       MSGLEVEL_CRAP, SILCTXT_CHANNEL_KICKED_YOU, 
                       channel_entry->channel_name, tmp ? tmp : "");
+    if (chanrec) {
+      chanrec->kicked = TRUE;
+      channel_destroy((CHANNEL_REC *)chanrec);
+    }
   } else {
     printformat_module("fe-common/silc", server, channel_entry->channel_name,
                       MSGLEVEL_CRAP, SILCTXT_CHANNEL_KICKED, 
                       client_entry->nickname,
                       channel_entry->channel_name, tmp ? tmp : "");
+
+    if (chanrec) {
+      SILC_NICK_REC *nickrec = silc_nicklist_find(chanrec, client_entry);
+      if (nickrec != NULL)
+       nicklist_remove(CHANNEL(chanrec), NICK(nickrec));
+    }
   }
 }
 
@@ -472,7 +485,7 @@ static void command_part(const char *data, SILC_SERVER_REC *server,
   if (!IS_SILC_SERVER(server) || !server->connected)
     cmd_return_error(CMDERR_NOT_CONNECTED);
 
-  if (*data == '\0') {
+  if (!strcmp(data, "*") || *data == '\0') {
     if (!IS_SILC_CHANNEL(item))
       cmd_return_error(CMDERR_NOT_JOINED);
     data = item->name;