Selaa lähdekoodia

* Port [3009] to 1.2.11
* Misc comments - cleanups
* Took out info_party


svn: 3010

Bryan Drewery 20 vuotta sitten
vanhempi
commit
6f4cbdab5d
5 muutettua tiedostoa jossa 4 lisäystä ja 23 poistoa
  1. 1 1
      src/botnet.c
  2. 3 2
      src/dcc.c
  3. 0 5
      src/dccutil.c
  4. 0 1
      src/dccutil.h
  5. 0 14
      src/mod/console.mod/console.c

+ 1 - 1
src/botnet.c

@@ -1655,7 +1655,7 @@ void check_botnet_pings()
   }
 
   if (top_index != (dcc_total - 1))
-    trim_dcclist(top_index);
+    dcc_total = top_index + 1;
 }
 
 void zapfbot(int idx)

+ 3 - 2
src/dcc.c

@@ -1194,15 +1194,16 @@ dcc_chat(int idx, char *buf, int len)
             dprintf(i, "=%s=> %s\n", dcc[idx].nick, buf + 1);
         }
       }
-    } else {
+    } else { /* partyline chat */
       if (dcc[idx].u.chat->away != NULL)
         not_away(idx);
+      /* Check for CTCP (/me) */
       if (!strncmp(buf, "CTCP_MESSAGE ", 13))		/* irssi */
         buf += 13;
       if (!strncmp(buf, "ACTION ", 7)) {
         buf += 7;
         check_bind_dcc("me", idx, buf);
-      } else {
+      } else {		/* regular text */
         if (dcc[idx].status & STAT_ECHO)
           chanout_but(-1, dcc[idx].u.chat->channel, "<%s> %s\n", dcc[idx].nick, buf);
         else

+ 0 - 5
src/dccutil.c

@@ -425,11 +425,6 @@ dcc_chatter(int idx)
   }
 }
 
-void trim_dcclist(int top_index)
-{
-  dcc_total = top_index + 1;    
-}
-
 int
 dcc_read(FILE *f)
 {

+ 0 - 1
src/dccutil.h

@@ -36,7 +36,6 @@ void dprintf(int, const char *, ...) __attribute__((format(printf, 2, 3)));
 void chatout(const char *, ...) __attribute__((format(printf, 1, 2)));
 void chanout_but(int, int, const char *, ...) __attribute__((format(printf, 3, 4)));
 void dcc_chatter(int);
-void trim_dcclist(int);
 void lostdcc(int);
 void makepass(char *);
 void tell_dcc(int);

+ 0 - 14
src/mod/console.mod/console.c

@@ -21,7 +21,6 @@
 #include "src/core_binds.h"
 
 static int console_autosave = 1;
-static int info_party = 1;
 
 struct console_info {
   char *channel;
@@ -281,19 +280,6 @@ console_chon(char *handle, int idx)
     if ((dcc[idx].u.chat->channel >= 0) && (dcc[idx].u.chat->channel < GLOBAL_CHANS)) {
       botnet_send_join_idx(idx);
     }
-    if (info_party) {
-      char *p = (char *) get_user(&USERENTRY_INFO, dcc[idx].user);
-
-      if (p) {
-        if (dcc[idx].u.chat->channel >= 0) {
-          char x[1024] = "";
-
-          chanout_but(-1, dcc[idx].u.chat->channel, "*** [%s] %s\n", dcc[idx].nick, p);
-          simple_sprintf(x, "[%s] %s", dcc[idx].nick, p);
-          botnet_send_chan(-1, conf.bot->nick, NULL, dcc[idx].u.chat->channel, x);
-        }
-      }
-    }
   }
   return 0;
 }