Sfoglia il codice sorgente

* Ported [2628] to 1.2.9 (fixes #192)

svn: 2629
Bryan Drewery 20 anni fa
parent
commit
f340467b70
2 ha cambiato i file con 5 aggiunte e 1 eliminazioni
  1. 1 0
      doc/UPDATES
  2. 4 1
      src/cmds.c

+ 1 - 0
doc/UPDATES

@@ -48,6 +48,7 @@ Lines prefixed with '-' were disabled before release and are not finished, or ar
 * Fixed returning from 'su' not returning user to correct channel. (ie, partyline)
 * Fixed cmds showing failed cmdpass. (#188)
 * The respository is now stored in subversion; binaries now hold a revision number.
+* cmd_botcmd <?> now displays which bot is chosen in the log. (#192)
 
 1.2.8
 * Fixed [bot]* cmds depending on case of botnicks.

+ 4 - 1
src/cmds.c

@@ -1283,7 +1283,8 @@ static void cmd_botcmd(int idx, char *par)
   tand_t *tbot = NULL;
 
   /* the rest of the cmd will be logged remotely */
-  putlog(LOG_CMDS, "*", "#%s# botcmd %s %s ...", dcc[idx].nick, botm, cmd);	
+  if (strcmp(botm, "?"))
+    putlog(LOG_CMDS, "*", "#%s# botcmd %s %s ...", dcc[idx].nick, botm, cmd);
 
   if (!strcmp(botm, "*")) {
     if (!egg_strncasecmp(cmd, "di", 2) || (!egg_strncasecmp(cmd, "res", 3) && egg_strncasecmp(cmd, "reset", 5)) || !egg_strncasecmp(cmd, "sui", 3) || 
@@ -1322,6 +1323,8 @@ static void cmd_botcmd(int idx, char *par)
       continue;
     cnt++;
     if ((rleaf != -1 && cnt == rleaf) || (rleaf == -1 && (all_localhub || wild_match(botm, tbot->bot)))) {
+      if (rleaf != -1)
+        putlog(LOG_CMDS, "*", "#%s# botcmd %s %s ...", dcc[idx].nick, tbot->bot, cmd);
       send_remote_simul(idx, tbot->bot, cmd, par ? par : (char *) "");
       found++;
     }