]> git.netwichtig.de Git - user/henk/code/inspircd.git/commitdiff
Whoops, forgot some stuff for when GECOS was moved to position 10 in the UID command...
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>
Sun, 30 Sep 2007 18:14:51 +0000 (18:14 +0000)
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>
Sun, 30 Sep 2007 18:14:51 +0000 (18:14 +0000)
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8102 e03df62e-2008-0410-955e-edbf42e46eb7

src/modules/m_spanningtree/treesocket1.cpp
src/users.cpp

index 2c8fc34a91f9042dc85c019916ff7d9d3562bc63..b954ade9bfd1e662720e499abf9b4f8310c8de23 100644 (file)
@@ -1083,7 +1083,7 @@ bool TreeSocket::ParseUID(const std::string &source, std::deque<std::string> &pa
        strlcpy(_new->dhost, params[4].c_str(),64);
        _new->server = this->Instance->FindServerNamePtr(source.c_str());
        strlcpy(_new->ident, params[5].c_str(),IDENTMAX);
-       strlcpy(_new->fullname, params[8].c_str(),MAXGECOS);
+       strlcpy(_new->fullname, params[9].c_str(),MAXGECOS);
        _new->registered = REG_ALL;
        _new->signon = signon;
        _new->age = age;
@@ -1123,7 +1123,7 @@ bool TreeSocket::ParseUID(const std::string &source, std::deque<std::string> &pa
        if (dosend)
                this->Instance->SNO->WriteToSnoMask('C',"Client connecting at %s: %s!%s@%s [%s] [%s]",_new->server,_new->nick,_new->ident,_new->host, _new->GetIPString(), _new->fullname);
 
-       params[8] = ":" + params[8];
+       params[9] = ":" + params[9];
        Utils->DoOneToAllButSender(source, "UID", params, source);
 
        // Increment the Source Servers User Count..
index 4f5c567d253f222e49fb5dd49902eed6fa00c45f..8ab475bd9e9278754cb80ee0ab9df05b42b2bdf9 100644 (file)
@@ -309,13 +309,18 @@ const char* userrec::FormatModes()
 
 void userrec::DecrementModes()
 {
-       for (int n = 0; n < 64; n++)
+       ServerInstance->Log(DEBUG,"DecrementModes()");
+       for (unsigned char n = 'A'; n <= 'z'; n++)
        {
-               if (modes[n])
+               if (modes[n-65])
                {
-                       ModeHandler* mh = ServerInstance->Modes->FindMode(n+65, MODETYPE_USER);
+                       ServerInstance->Log(DEBUG,"DecrementModes() found mode %c", n);
+                       ModeHandler* mh = ServerInstance->Modes->FindMode(n, MODETYPE_USER);
                        if (mh)
+                       {
+                               ServerInstance->Log(DEBUG,"Found handler %c and call ChangeCount", n);
                                mh->ChangeCount(-1);
+                       }
                }
        }
 }