Committer : entrope
CVSROOT : /cvsroot/undernet-ircu
Module : ircu2.10
Commit time: 2004-12-18 04:45:59 UTC
Modified files:
ircd/channel.c
Log message:
Fix thinko that should have been obvious.
---------------------- diff included ----------------------
Index: ircu2.10/ircd/channel.c
diff -u ircu2.10/ircd/channel.c:1.113 ircu2.10/ircd/channel.c:1.114
--- ircu2.10/ircd/channel.c:1.113 Fri Dec 17 20:41:06 2004
+++ ircu2.10/ircd/channel.c Fri Dec 17 20:45:49 2004
@@ -19,7 +19,7 @@
*/
/** @file
* @brief Channel management and maintanance
- * @version $Id: channel.c,v 1.113 2004/12/18 04:41:06 entrope Exp $
+ * @version $Id: channel.c,v 1.114 2004/12/18 04:45:49 entrope Exp $
*/
#include "config.h"
@@ -2683,7 +2683,7 @@
* @param[in] newban Ban (or exception) to add (or remove).
* @return Zero if \a newban could be applied, non-zero if not.
*/
-int apply_ban(struct Ban **banlist, struct Ban *newban, int free)
+int apply_ban(struct Ban **banlist, struct Ban *newban, int do_free)
{
struct Ban *ban;
size_t count = 0;
@@ -2694,7 +2694,7 @@
/* If a less specific entry is found, fail. */
for (ban = *banlist; ban; ban = ban->next) {
if (!bmatch(ban, newban)) {
- if (free)
+ if (do_free)
free_ban(newban);
return 1;
}
@@ -2721,14 +2721,15 @@
remove_count++;
}
}
- if (free)
+ if (do_free)
free_ban(newban);
else
MyFree(newban->banstr);
/* If no matches were found, fail. */
return remove_count ? 0 : 3;
}
- free_ban(newban);
+ if (do_free)
+ free_ban(newban);
return 4;
}
----------------------- End of diff -----------------------