summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorphil-lavin <phil-lavin@5417fbe8-f217-4b02-8779-1006273d7864>2010-06-04 09:57:54 +0000
committerphil-lavin <phil-lavin@5417fbe8-f217-4b02-8779-1006273d7864>2010-06-04 09:57:54 +0000
commitcea53460b02f51c1d91540f4d371262bf8bdfa63 (patch)
tree26910847268e0d469fc1312b9191bafa1b660931
parentd8642972d987d97ac4e1718e96666dae931447d2 (diff)
Moved EVENT_CHANGE_NICK call to after anope_cmd_nc_change() call
Added user identified check to validate_user() to prevent identified user being told to identify git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/stable@2999 5417fbe8-f217-4b02-8779-1006273d7864
-rw-r--r--Changes2
-rw-r--r--src/nickserv.c3
-rw-r--r--src/users.c5
-rw-r--r--version.log3
4 files changed, 10 insertions, 3 deletions
diff --git a/Changes b/Changes
index da76df863..2a5b9082e 100644
--- a/Changes
+++ b/Changes
@@ -13,6 +13,8 @@ Anope Version 1.8 - SVN
4/28 F Fixed a bug that could make some nick requests disappear [ #00]
5/18 F Fixed English and grammar in e-mail messages [ #00]
5/23 F Fixed SQUITing juped servers on InspIRCd 1.2 [#1165]
+6/4 F Check if user is identified before telling them to identify [ #00]
+6/4 F Moved EVENT_CHANGE_NICK call to after the nick change processing [ #00]
Anope Version 1.8.4
-------------------
diff --git a/src/nickserv.c b/src/nickserv.c
index 8b15d9920..1033e8596 100644
--- a/src/nickserv.c
+++ b/src/nickserv.c
@@ -1008,6 +1008,9 @@ int validate_user(User * u)
return 0;
}
+ if (na->status & NS_IDENTIFIED)
+ return 1;
+
on_access = is_on_access(u, na->nc);
if (on_access)
na->status |= NS_ON_ACCESS;
diff --git a/src/users.c b/src/users.c
index 6ce0c2c06..e55a68696 100644
--- a/src/users.c
+++ b/src/users.c
@@ -746,8 +746,6 @@ User *do_nick(const char *source, char *nick, char *username, char *host,
oldnick = sstrdup(user->nick);
change_user_nick(user, nick);
- send_event(EVENT_CHANGE_NICK, 2, nick, oldnick);
- free(oldnick);
if ((old_na ? old_na->nc : NULL) ==
(user->na ? user->na->nc : NULL))
@@ -758,6 +756,9 @@ User *do_nick(const char *source, char *nick, char *username, char *host,
else {
anope_cmd_nc_change(user);
}
+
+ send_event(EVENT_CHANGE_NICK, 2, nick, oldnick);
+ free(oldnick);
}
if (ircd->sqline) {
diff --git a/version.log b/version.log
index 736811f08..5a6ccb549 100644
--- a/version.log
+++ b/version.log
@@ -9,9 +9,10 @@ VERSION_MAJOR="1"
VERSION_MINOR="8"
VERSION_PATCH="4"
VERSION_EXTRA="-svn"
-VERSION_BUILD="2993"
+VERSION_BUILD="2999"
# $Log$ # Changes since the 1.8.4 Release
+#Revision 2999 - Moved EVENT_CHANGE_NICK call to after anope_cmd_nc_change() call. Added user identified check to validate_user() to prevent identified user being told to identify.
#Revision 2993 - Fixed db-mergers handling of bot collisions
#Revision 2991 - Fixed a crash on shutdown when running Anope on Mac
#Revision 2981 - Fixed SQUITing juped servers on InspIRCd 1.2