Selaa lähdekoodia

* Cleaned up two killsock() calls

svn: 1242
Bryan Drewery 22 vuotta sitten
vanhempi
commit
35660eaaaa
2 muutettua tiedostoa jossa 6 lisäystä ja 3 poistoa
  1. 1 1
      doc/UPDATES
  2. 5 2
      src/dcc.c

+ 1 - 1
doc/UPDATES

@@ -23,7 +23,7 @@ This is a summary of ChangeLog basically.
 * Users are no longer auto-opped on netsplit rejoin.
 * Passwords now require: 2lcase, 2ucase, 8 chars.
 * Moved config settings (bad-cookie, op-time-slack, manop, mdop, mop) to 'chanset'
-* Renamed 'op-time-slack' to 'cookie-time-slack'
+-REMOVE THIS ? * Renamed 'op-time-slack' to 'cookie-time-slack'
 * SIGHUP now restarts bot.
 * Fixed possible SEGFAULT on bot timeout.
 * Sped up mode parsing

+ 5 - 2
src/dcc.c

@@ -259,8 +259,10 @@ failed_link(int idx)
   }
   if (dcc[idx].u.bot->numver >= (-1))
     putlog(LOG_BOTS, "*", DCC_LINKFAIL, dcc[idx].nick);
-  if (dcc[idx].sock != -1)
+  if (dcc[idx].sock != -1) {
     killsock(dcc[idx].sock);
+    dcc[idx].sock = -1; 
+  }
   strcpy(s, dcc[idx].nick);
   lostdcc(idx);
   autolink_cycle(s);            /* Check for more auto-connections */
@@ -310,7 +312,8 @@ cont_link(int idx, char *buf, int ii)
     socklist[snum].encstatus = 1;
     socklist[snum].gz = 1;
   } else {
-    killsock(dcc[idx].sock);
+/* FIXME: This seems unnecesary, we didnt find a socket yet we are killing one.. ?*/
+  /*  killsock(dcc[idx].sock); */
     lostdcc(idx);
   }
   return;