From 57fb28e70a2096fcf7cb1ab5838de3ac19e4b56b Mon Sep 17 00:00:00 2001 From: cyberbotx Date: Mon, 23 Mar 2009 04:57:15 +0000 Subject: Backport of bugfix for bug #1044 from SVN r2195, CS SET MLOCK no longer requires a parameter, and leaving out the parameter renders the mlock to +r as it should be. git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/stable@2196 5417fbe8-f217-4b02-8779-1006273d7864 --- src/core/cs_set.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/core/cs_set.c b/src/core/cs_set.c index 43a191236..63d99b34e 100644 --- a/src/core/cs_set.c +++ b/src/core/cs_set.c @@ -185,7 +185,8 @@ int do_set(User * u) if (!param && (!cmd || (stricmp(cmd, "SUCCESSOR") != 0 && stricmp(cmd, "URL") != 0 && stricmp(cmd, "EMAIL") != 0 && - stricmp(cmd, "ENTRYMSG") != 0))) { + stricmp(cmd, "ENTRYMSG") != 0 && + stricmp(cmd, "MLOCK") != 0))) { syntax_error(s_ChanServ, u, "SET", CHAN_SET_SYNTAX); } else if (!(ci = cs_findchan(chan))) { notice_lang(s_ChanServ, u, CHAN_X_NOT_REGISTERED, chan); @@ -492,7 +493,7 @@ int do_set_mlock(User * u, ChannelInfo * ci, char *param) ci->mlock_redirect = NULL; } - while ((mode = *param++)) { + while (param && (mode = *param++)) { switch (mode) { case '+': add = 1; -- cgit