summaryrefslogtreecommitdiff
path: root/src/users.cpp
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2007-10-24 15:48:00 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2007-10-24 15:48:00 +0000
commitfa04fb00cf96c8af5045de576b146b3a09f9b2ed (patch)
treea007aa1dbf04dd98da30652bed6decc02e23d4e9 /src/users.cpp
parent5d6d076cc3e6585ec3b52e1b7281767ed4760cb0 (diff)
Try this w00t, compiles, test running now
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8343 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/users.cpp')
-rw-r--r--src/users.cpp18
1 files changed, 11 insertions, 7 deletions
diff --git a/src/users.cpp b/src/users.cpp
index 0e08a8848..08e38f36d 100644
--- a/src/users.cpp
+++ b/src/users.cpp
@@ -1725,9 +1725,11 @@ ConnectClass* User::SetClass(const std::string &explicit_name)
{
for (ClassVector::iterator i = ServerInstance->Config->Classes.begin(); i != ServerInstance->Config->Classes.end(); i++)
{
- if (explicit_name == i->GetName())
+ ConnectClass* c = *i;
+
+ if (explicit_name == c->GetName())
{
- found = &(*i);
+ found = c;
}
}
}
@@ -1735,20 +1737,22 @@ ConnectClass* User::SetClass(const std::string &explicit_name)
{
for (ClassVector::iterator i = ServerInstance->Config->Classes.begin(); i != ServerInstance->Config->Classes.end(); i++)
{
- if (((match(this->GetIPString(),i->GetHost().c_str(),true)) || (match(this->host,i->GetHost().c_str()))))
+ ConnectClass* c = *i;
+
+ if (((match(this->GetIPString(),c->GetHost().c_str(),true)) || (match(this->host,c->GetHost().c_str()))))
{
- if (i->GetPort())
+ if (c->GetPort())
{
- if (this->GetPort() == i->GetPort())
+ if (this->GetPort() == c->GetPort())
{
- found = &(*i);
+ found = c;
}
else
continue;
}
else
{
- found = &(*i);
+ found = c;
}
}
}