Переглянути джерело

Merge branch '77-remove-chanlimit' into next

* 77-remove-chanlimit:
  Update docs
  Remove channel limit when limitraise is disabled (#76)

Conflicts:
	doc/UPDATES
Bryan Drewery 12 роки тому
батько
коміт
53218b90ea
2 змінених файлів з 3 додано та 0 видалено
  1. 1 0
      doc/UPDATES
  2. 2 0
      src/mod/channels.mod/chanmisc.c

+ 1 - 0
doc/UPDATES

@@ -2,6 +2,7 @@ next
   * Bot will now jump from the server it's on if it is removed from the server list. (fixes a changing network bug)
   * Properly honor exemptions when kicking matched RBL clients
   * Fix LASTON not being shared
+  * Remove channel limit when limitraise is disabled (#77)
 
 maint
   * Read in /etc/hosts on startup

+ 2 - 0
src/mod/channels.mod/chanmisc.c

@@ -385,6 +385,8 @@ int channel_modify(char *result, struct chanset_t *chan, int items, char **item,
           strlcpy(result, "channel limit needs argument", RESULT_LEN);
         return ERROR;
       }
+      if (chan->limitraise && !atoi(item[i]) && dolimit(chan)) //limitraise was disabled by the user
+        add_mode(chan, '-', 'l', "");
       chan->limitraise = atoi(item[i]);
       chan->limit_prot = 0;
     } else if (!strcmp(item[i], "fish-key")) {