summaryrefslogtreecommitdiff
path: root/src/modules/m_conn_waitpong.cpp
diff options
context:
space:
mode:
authordanieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7>2009-09-02 00:49:36 +0000
committerdanieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7>2009-09-02 00:49:36 +0000
commit86775e2e98f55b3b88befe2daff0ca23f02f3155 (patch)
treecbc3abf3f55ae6fd1112bcf6bf44e02b502ac2d6 /src/modules/m_conn_waitpong.cpp
parent3d8ec5dbd9cfde34fcbc63ad7b9b1369866f0a33 (diff)
ModResult conversion: Change return type of all module functions
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11634 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/modules/m_conn_waitpong.cpp')
-rw-r--r--src/modules/m_conn_waitpong.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/modules/m_conn_waitpong.cpp b/src/modules/m_conn_waitpong.cpp
index 9a0adc3d6..4da240138 100644
--- a/src/modules/m_conn_waitpong.cpp
+++ b/src/modules/m_conn_waitpong.cpp
@@ -56,7 +56,7 @@ class ModuleWaitPong : public Module
return (char*)out;
}
- virtual int OnUserRegister(User* user)
+ virtual ModResult OnUserRegister(User* user)
{
char* pingrpl = RandString(10);
@@ -66,10 +66,10 @@ class ModuleWaitPong : public Module
user->WriteServ("NOTICE %s :*** If you are having problems connecting due to ping timeouts, please type /quote PONG %s or /raw PONG %s now.", user->nick.c_str(), pingrpl, pingrpl);
user->Extend(extenstr, pingrpl);
- return 0;
+ return MOD_RES_PASSTHRU;
}
- virtual int OnPreCommand(std::string &command, std::vector<std::string> &parameters, User* user, bool validated, const std::string &original_line)
+ virtual ModResult OnPreCommand(std::string &command, std::vector<std::string> &parameters, User* user, bool validated, const std::string &original_line)
{
if (command == "PONG")
{
@@ -82,23 +82,23 @@ class ModuleWaitPong : public Module
{
delete[] pingrpl;
user->Shrink(extenstr);
- return 1;
+ return MOD_RES_DENY;
}
else
{
if(killonbadreply)
ServerInstance->Users->QuitUser(user, "Incorrect ping reply for registration");
- return 1;
+ return MOD_RES_DENY;
}
}
}
- return 0;
+ return MOD_RES_PASSTHRU;
}
- virtual bool OnCheckReady(User* user)
+ virtual ModResult OnCheckReady(User* user)
{
char* pingrpl;
- return (!user->GetExt(extenstr, pingrpl));
+ return user->GetExt(extenstr, pingrpl) ? MOD_RES_DENY : MOD_RES_PASSTHRU;
}
virtual void OnUserDisconnect(User* user)