Some minor optimizations

I doubt this makes much of a difference, but some callgrind run with one hour
of #ubuntu pointed to this stuff. Let's hope it's at least a little little
little bit faster now


git-svn-id: https://znc.svn.sourceforge.net/svnroot/znc/trunk@1527 726aef4b-f618-498e-8847-2d620e286838
This commit is contained in:
psychon
2009-05-29 20:26:37 +00:00
parent aae356c8d5
commit ffe92a4b66
2 changed files with 8 additions and 4 deletions
+7 -3
View File
@@ -401,9 +401,13 @@ bool CChan::AddNick(const CString& sNick) {
}
sTmp = p;
sIdent = sTmp.Token(1, true, "!").Token(0, false, "@");
sHost = sTmp.Token(1, true, "@");
sTmp = sTmp.Token(0, false, "!");
// The UHNames extension gets us nick!ident@host instead of just plain nick
sIdent = sTmp.Token(1, true, "!");
sHost = sIdent.Token(1, true, "@");
sIdent = sIdent.Token(0, false, "@");
// Get the nick
sTmp = sTmp.Token(0, false, "!");
CNick* pNick = FindNick(sTmp);
if (!pNick) {