]> jfr.im git - irc/evilnet/x3.git/blobdiff - src/proto-p10.c
This is a spam checking module, remember to disable it just comment out the nick...
[irc/evilnet/x3.git] / src / proto-p10.c
index 7d17423f9b3a734ae2fd826de0a20b260e125e03..333ec571a7050c4723239ff75360f8b98fd4fb32 100644 (file)
@@ -925,12 +925,15 @@ irc_topic(struct userNode *service, struct userNode *who, struct chanNode *what,
    int type = 4;
    const char *str;
    str = conf_get_data("server/type", RECDB_QSTRING);
-   type = atoi(str);
+   if(str)
+     type = atoi(str);
+   else
+     type = 4;/* default to 040 style topics */
 
    if (type == 5) {
      putsock("%s " P10_TOPIC " %s %s " FMT_TIME_T " " FMT_TIME_T " :%s", service->numeric, what->name, who->nick, what->timestamp, now, topic);
    } else {
-     who = service; /* REMOVE LINE FOR NEFARIOUS 0.5.0 */
+     who = service;
      putsock("%s " P10_TOPIC " %s :%s", who->numeric, what->name, topic);
    }
 }