summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/mode.cpp14
-rwxr-xr-xsrc/svn-rev.sh2
2 files changed, 3 insertions, 13 deletions
diff --git a/src/mode.cpp b/src/mode.cpp
index b018d9117..8a85a621b 100644
--- a/src/mode.cpp
+++ b/src/mode.cpp
@@ -449,8 +449,7 @@ std::string ModeParser::CompressModes(std::string modes,bool channelmodes)
void ModeParser::ProcessModes(char **parameters,userrec* user,chanrec *chan,int status, int pcnt, bool servermode, bool silent, bool local)
{
- if (!parameters) {
- log(DEFAULT,"*** BUG *** process_modes was given an invalid parameter");
+ if ((!parameters) || (pcnt < 2)) {
return;
}
@@ -463,11 +462,6 @@ void ModeParser::ProcessModes(char **parameters,userrec* user,chanrec *chan,int
char* r = NULL;
bool k_set = false, l_set = false, previously_set_l = false, previously_unset_l = false, previously_set_k = false, previously_unset_k = false;
- if (pcnt < 2)
- {
- return;
- }
-
int MOD_RESULT = 0;
if (IS_LOCAL(user))
@@ -477,8 +471,6 @@ void ModeParser::ProcessModes(char **parameters,userrec* user,chanrec *chan,int
return;
}
- log(DEBUG,"process_modes: start: parameters=%d",pcnt);
-
char* modelist = parameters[1]; /* mode list, e.g. +oo-o *
* parameters[2] onwards are parameters for
* modes that require them :) */
@@ -496,9 +488,7 @@ void ModeParser::ProcessModes(char **parameters,userrec* user,chanrec *chan,int
while (modelist[len-1] == ' ')
modelist[--len] = '\0';
- char* modechar;
-
- for (modechar = (modelist + 1); *modechar; ptr++, modechar++)
+ for (char* modechar = (modelist + 1); *modechar; ptr++, modechar++)
{
r = NULL;
diff --git a/src/svn-rev.sh b/src/svn-rev.sh
index 15886b3ba..2d650a126 100755
--- a/src/svn-rev.sh
+++ b/src/svn-rev.sh
@@ -1 +1 @@
-echo 3482
+echo 3484