]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_ident.cpp
(Hopefully) fix a issue with m_ident's result not being used for display.
[user/henk/code/inspircd.git] / src / modules / m_ident.cpp
index 6db5847537af9b64e6830c54637189b8b799765c..71767e554866d88e4cd99f4893bb24a44f2bfa9e 100644 (file)
@@ -323,7 +323,7 @@ class ModuleIdent : public Module
        ModuleIdent(InspIRCd *Me) : Module(Me)
        {
                Conf = new ConfigReader(ServerInstance);
-               OnRehash(NULL, "");
+               OnRehash(NULL);
                Implementation eventlist[] = { I_OnRehash, I_OnUserRegister, I_OnCheckReady, I_OnCleanup, I_OnUserDisconnect };
                ServerInstance->Modules->Attach(eventlist, this, 5);
        }
@@ -338,7 +338,7 @@ class ModuleIdent : public Module
                return Version("$Id$", VF_VENDOR, API_VERSION);
        }
 
-       virtual void OnRehash(User *user, const std::string &param)
+       virtual void OnRehash(User *user)
        {
                delete Conf;
                Conf = new ConfigReader(ServerInstance);
@@ -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);