summaryrefslogtreecommitdiff
path: root/src/nickserv.c
diff options
context:
space:
mode:
authortrystan trystan@31f1291d-b8d6-0310-a050-a5561fc1590b <trystan trystan@31f1291d-b8d6-0310-a050-a5561fc1590b@5417fbe8-f217-4b02-8779-1006273d7864>2004-12-26 06:11:14 +0000
committertrystan trystan@31f1291d-b8d6-0310-a050-a5561fc1590b <trystan trystan@31f1291d-b8d6-0310-a050-a5561fc1590b@5417fbe8-f217-4b02-8779-1006273d7864>2004-12-26 06:11:14 +0000
commit90974e3636f34fd3a9e49c37b8dae4a357ea070a (patch)
tree2bd623f17230470858b420b126cdde630f554ea3 /src/nickserv.c
parent92d13d1e06bf94e94feb5174a1d38a4c3c1f4217 (diff)
BUILD : 1.7.6 (503) BUGS : N/A NOTES : Fixes alot of user and channel modes on various ircd, also applied two patches provided by DrStein
git-svn-id: svn://svn.anope.org/anope/trunk@503 31f1291d-b8d6-0310-a050-a5561fc1590b git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@357 5417fbe8-f217-4b02-8779-1006273d7864
Diffstat (limited to 'src/nickserv.c')
-rw-r--r--src/nickserv.c12
1 files changed, 10 insertions, 2 deletions
diff --git a/src/nickserv.c b/src/nickserv.c
index 5cc4c48d9..631003b50 100644
--- a/src/nickserv.c
+++ b/src/nickserv.c
@@ -4055,11 +4055,16 @@ static int do_ghost(User * u)
static int do_status(User * u)
{
- char *nick;
User *u2;
int i = 0;
+ char *nick = strtok(NULL, " ");
+
+ /* If no nickname is given, we assume that the user
+ * is asking for himself */
+ if (!nick)
+ nick = u->nick;
- while ((nick = strtok(NULL, " ")) && (i++ < 16)) {
+ while (nick && (i++ < 16)) {
if (!(u2 = finduser(nick)))
notice_lang(s_NickServ, u, NICK_STATUS_0, nick);
else if (nick_identified(u2))
@@ -4068,6 +4073,9 @@ static int do_status(User * u)
notice_lang(s_NickServ, u, NICK_STATUS_2, nick);
else
notice_lang(s_NickServ, u, NICK_STATUS_1, nick);
+
+ /* Get the next nickname */
+ nick = strtok(NULL, " ");
}
return MOD_CONT;
}