summaryrefslogtreecommitdiff
path: root/src/cmd_user.cpp
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2006-07-28 12:00:25 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2006-07-28 12:00:25 +0000
commit95840640cb374a0845c866bd1ad56a04dd833081 (patch)
tree17fb64980c11b26d33967f58064f3579d2a1ca4d /src/cmd_user.cpp
parent9296aee7bc95c0fb2a0d00f76b908eba99e730af (diff)
Change all references to voodoo numbers (7, 3 etc) to the new bitwise constants for user->registered
Change a lot of user->fd > -1 to use the IS_LOCAL() macro git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4569 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/cmd_user.cpp')
-rw-r--r--src/cmd_user.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/cmd_user.cpp b/src/cmd_user.cpp
index f493f76c1..67b7c9492 100644
--- a/src/cmd_user.cpp
+++ b/src/cmd_user.cpp
@@ -29,7 +29,7 @@ extern FactoryList factory;
void cmd_user::Handle (const char** parameters, int pcnt, userrec *user)
{
- if (user->registered < 3)
+ if (user->registered < REG_NICKUSER)
{
if (!isident(parameters[0])) {
// This kinda Sucks, According to the RFC thou, its either this,
@@ -43,7 +43,7 @@ void cmd_user::Handle (const char** parameters, int pcnt, userrec *user)
*/
snprintf(user->ident, IDENTMAX+1, "~%s", parameters[0]);
strlcpy(user->fullname,parameters[3],MAXGECOS);
- user->registered = (user->registered | 1);
+ user->registered = (user->registered | REG_USER);
}
}
else
@@ -52,7 +52,7 @@ void cmd_user::Handle (const char** parameters, int pcnt, userrec *user)
return;
}
/* parameters 2 and 3 are local and remote hosts, ignored when sent by client connection */
- if (user->registered == 3)
+ if (user->registered == REG_NICKUSER)
{
/* user is registered now, bit 0 = USER command, bit 1 = sent a NICK command */
FOREACH_MOD(I_OnUserRegister,OnUserRegister(user));