]> jfr.im git - irc/evilnet/x3.git/blobdiff - src/spamserv.c
Fixed a typo in ROUTING EXAMPLE
[irc/evilnet/x3.git] / src / spamserv.c
index 0c871eb2cbb84987af244b7515e45447e7106cb3..cc0980032ec56ad38c2b2b722288283ebd6df2ac 100644 (file)
@@ -3,7 +3,7 @@
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
+ * the Free Software Foundation; either version 3 of the License, or
  * (at your option) any later version.  Important limitations are
  * listed in the COPYING file that accompanies this software.
  *
@@ -596,8 +596,8 @@ spamserv_create_user(struct userNode *user)
 
        if(kNode)
        {
+               /* free(kNode); dict_remove does this */
                dict_remove(killed_users_dict, irc_ntoa(&user->ip));
-               free(kNode);
        }
 }
 
@@ -2083,7 +2083,7 @@ static SPAMSERV_FUNC(cmd_addtrust)
     struct handle_info *hi;
 
     if (!(channel = GetChannel(argv[2]))) {
-        ss_reply("SSMSG_NOT_REGISTERED", channel->name);
+        ss_reply("SSMSG_NOT_REGISTERED", argv[2]);
         return 0;
     }
 
@@ -2210,7 +2210,7 @@ static SPAMSERV_FUNC(cmd_deltrust)
     struct handle_info *hi;
 
     if (!(channel = GetChannel(argv[2]))) {
-        ss_reply("SSMSG_NOT_REGISTERED", channel->name);
+        ss_reply("SSMSG_NOT_REGISTERED", argv[2]);
         return 0;
     }
 
@@ -3218,7 +3218,7 @@ init_spamserv(const char *nick)
                return;
 
         const char *modes = conf_get_data("services/spamserv/modes", RECDB_QSTRING);
-       spamserv = AddService(nick, modes ? modes : NULL, "Anti Spam Services", NULL);
+        spamserv = AddLocalUser(nick, nick, NULL, "Anti Spam Services", modes);
        spamserv_service = service_register(spamserv);
 
        conf_register_reload(spamserv_conf_read);