diff options
Diffstat (limited to 'src/modules/m_spanningtree')
-rw-r--r-- | src/modules/m_spanningtree/uid.cpp | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/src/modules/m_spanningtree/uid.cpp b/src/modules/m_spanningtree/uid.cpp index de3b669c4..b0f5df21d 100644 --- a/src/modules/m_spanningtree/uid.cpp +++ b/src/modules/m_spanningtree/uid.cpp @@ -119,13 +119,20 @@ bool TreeSocket::ParseUID(const std::string &source, std::deque<std::string> &pa if (mh) { - if (mh->GetNumParams(true) && (paramptr < params.size() - 1)) - mh->OnModeChange(_new, _new, NULL, params[paramptr++], true); + if (mh->GetNumParams(true)) + { + if (paramptr < params.size() - 1) + mh->OnModeChange(_new, _new, NULL, params[paramptr++], true); + else + Instance->Logs->Log("m_spanningtree", DEBUG, "Warning: Broken UID command, expected a parameter for user mode '%c' but there aren't enough parameters in the command!", *v); + } else mh->OnModeChange(_new, _new, NULL, empty, true); _new->SetMode(*v, true); mh->ChangeCount(1); } + else + Instance->Logs->Log("m_spanningtree", DEBUG, "Warning: Broken UID command, unknown user mode '%c' in the mode string!", *v); } //_new->ProcessNoticeMasks(params[7].c_str()); |