Bläddra i källkod

* Ported [2533] to 1.2.9 (fixes #190)

svn: 2617
Bryan Drewery 20 år sedan
förälder
incheckning
1290798136
2 ändrade filer med 3 tillägg och 1 borttagningar
  1. 1 0
      doc/UPDATES
  2. 2 1
      src/botcmd.c

+ 1 - 0
doc/UPDATES

@@ -42,6 +42,7 @@ Lines prefixed with '-' were disabled before release and are not finished, or ar
 * Fixed chanset 'flood-*' not working correctly. (#69)
 * Fixed cmd_rehash killing hubs. And revised help for 'rehash'. (#186)
 * Fixed a bug in the listen code, which caused a segfault in /ctcp chat (a few other places too) (#189)
+* Fixed botcmd using wrong user on remote bot after doing su'ing to another user. (#190)
 
 1.2.8
 * Fixed [bot]* cmds depending on case of botnicks.

+ 2 - 1
src/botcmd.c

@@ -1207,7 +1207,8 @@ static void bot_rsim(char *botnick, char *code, char *msg)
   }
 
   for (i = 0; i < dcc_total; i++) {
-   if (dcc[i].type && dcc[i].simul == ridx) {
+   /* See if we can find a simul-idx for the same ridx/nick */
+   if (dcc[i].type && dcc[i].simul == ridx && !egg_strcasecmp(dcc[i].nick, nick)) {
      putlog(LOG_DEBUG, "*", "Simul found old idx for %s: %d (ridx: %d)", nick, i, ridx);
      dcc[i].simultime = now;
      idx = i;