diff options
author | psychon <psychon@e03df62e-2008-0410-955e-edbf42e46eb7> | 2009-08-14 19:50:53 +0000 |
---|---|---|
committer | psychon <psychon@e03df62e-2008-0410-955e-edbf42e46eb7> | 2009-08-14 19:50:53 +0000 |
commit | 32810ff62b41cff00b9d664f62e570046c3a57a9 (patch) | |
tree | 4401435fc3e774f70c92cae5bc6b7f6ff610751a /src/modules/m_ident.cpp | |
parent | a9f3a0a0d4960cbd579e88b3a0e98867c7264a7a (diff) |
(Hopefully) fix a issue with m_ident's result not being used for display.
The user class has a couple of caches for the user's hostmask. If one of those
caches is initialized before m_ident set the user's new ident it would stick
around until the cache was invalidated the next time. This patch fixes this by
using the proper API for setting a user's ident which also invalidates any
caches which might still have the old ident.
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11514 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/modules/m_ident.cpp')
-rw-r--r-- | src/modules/m_ident.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/modules/m_ident.cpp b/src/modules/m_ident.cpp index 24e27d560..71767e554 100644 --- a/src/modules/m_ident.cpp +++ b/src/modules/m_ident.cpp @@ -452,7 +452,9 @@ class ModuleIdent : public Module user->WriteServ("NOTICE Auth :*** Could not find your ident, using %s instead.", isock->GetResult()); /* Copy the ident string to the user */ - user->ident.assign(isock->GetResult(), 0, ServerInstance->Config->Limits.IdentMax + 1); + std::string ident; + ident.assign(isock->GetResult(), 0, ServerInstance->Config->Limits.IdentMax + 1); + user->ChangeIdent(ident.c_str()); /* The user isnt actually disconnecting, we call this to clean up the user */ OnUserDisconnect(user); |