diff options
author | w00t <w00t@e03df62e-2008-0410-955e-edbf42e46eb7> | 2008-04-11 14:27:26 +0000 |
---|---|---|
committer | w00t <w00t@e03df62e-2008-0410-955e-edbf42e46eb7> | 2008-04-11 14:27:26 +0000 |
commit | d75ec0e5a59c32069b15e6ecf91d71ed62c21442 (patch) | |
tree | 543edee8012a9cd49cde5a9555101607aa588f7d /src/users.cpp | |
parent | e20a0915892b965b345db80d25fed25b8ef3a52f (diff) |
Patch from Brain fixing broken stuff
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@9456 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/users.cpp')
-rw-r--r-- | src/users.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/users.cpp b/src/users.cpp index 80515ffb8..6efbee651 100644 --- a/src/users.cpp +++ b/src/users.cpp @@ -191,7 +191,7 @@ User::User(InspIRCd* Instance, const std::string &uid) : ServerInstance(Instance Penalty = 0; lines_in = lastping = signon = idle_lastmsg = nping = registered = 0; ChannelCount = timeout = bytes_in = bytes_out = cmds_in = cmds_out = 0; - is4in6 = quietquit = OverPenalty = ExemptFromPenalty = quitting = exempt = haspassed = dns_done = false; + quietquit = OverPenalty = ExemptFromPenalty = quitting = exempt = haspassed = dns_done = false; fd = -1; recvq.clear(); sendq.clear(); @@ -1030,8 +1030,6 @@ void User::SetSockAddr(int protocol_family, const char* sip, int port) ServerInstance->Logs->Log("USERS",DEBUG,"Uh oh, I dont know protocol %d to be set on '%s'!", protocol_family, this->nick); break; } - - is4in6 = !strncmp(GetIPString(), "0::ffff:", 8); } int User::GetPort() @@ -1098,7 +1096,7 @@ const char* User::GetIPString(bool translate4in6) { strlcpy(&temp[1], buf, sizeof(temp) - 1); *temp = '0'; - if (translate4in6 && is4in6) + if (translate4in6 && !strncmp(GetIPString(), "0::ffff:", 8)) { this->cachedip = temp + 8; return temp + 8; |