@@ -4,6 +4,7 @@ Lines prefixed with '-' were disabled before release and are not finished, or ar
1.2.13 - http://wraith.shatow.net/milestone/1.2.13
* Fix cmd_chanset accepting invalid flags
+* Fix Auth system not tracking nick changes correctly. (fixes #318)
1.2.12 - http://wraith.shatow.net/milestone/1.2.12
* Clearing a variable via 'set var -' now resets that variable to default settings. (implements #111)
@@ -93,6 +93,10 @@ void Auth::Done(bool _bd)
bd = _bd;
}
+void Auth::NewNick(const char *newnick) {
+ strlcpy(nick, newnick, nick_len + 1);
+}
+
Auth *Auth::Find(const char *_host)
{
if (ht_host) {
@@ -105,6 +109,7 @@ Auth *Auth::Find(const char *_host)
return NULL;
Auth *Auth::Find(const char *handle, bool _hand)
if (ht_handle) {
@@ -21,6 +21,7 @@ class Auth {
bool Authed() { return (status == AUTHED); }
bool GetIdx(const char *);
void Done(bool = 0);
+ void NewNick(const char *nick);
static Auth *Find(const char * host);
static Auth *Find(const char * handle, bool _hand);
@@ -2705,6 +2705,11 @@ static int gotnick(char *from, char *msg)
fixcolon(msg);
irc_log(NULL, "[%s] Nick change: %s -> %s", samechans(nick, ","), nick, msg);
clear_chanlist_member(nick); /* Cache for nick 'nick' is meaningless now. */
+ Auth *auth = Auth::Find(uhost);
+ if (auth)
+ auth->NewNick(msg);
for (struct chanset_t *chan = chanset; chan; chan = chan->next) {
oldchan = chan;
chname = chan->dname;