diff options
Diffstat (limited to 'src/modules')
-rw-r--r-- | src/modules/m_conn_waitpong.cpp | 22 |
1 files changed, 13 insertions, 9 deletions
diff --git a/src/modules/m_conn_waitpong.cpp b/src/modules/m_conn_waitpong.cpp index a97e7f72c..83958ee2d 100644 --- a/src/modules/m_conn_waitpong.cpp +++ b/src/modules/m_conn_waitpong.cpp @@ -82,16 +82,20 @@ class ModuleWaitPong : public Module { char* pingrpl = user->GetExt("waitpong_pingstr"); - if(pingrpl && (strcmp(pingrpl, parameters[0]) == 0)) - { - delete pingrpl; - user->Shrink("waitpong_pingstr"); - return 1; - } - else if(killonbadreply) + if(pingrpl) { - Srv->QuitUser(user, "Incorrect ping reply for registration"); - return 1; + if(strcmp(pingrpl, parameters[0]) == 0) + { + delete pingrpl; + user->Shrink("waitpong_pingstr"); + return 1; + } + else + { + if(killonbadreply) + Srv->QuitUser(user, "Incorrect ping reply for registration"); + return 1; + } } } |