summaryrefslogtreecommitdiff
path: root/src/users.cpp
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2004-04-01 20:21:06 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2004-04-01 20:21:06 +0000
commit0ae832406f989194761528a1b8d49aa115c7fb3b (patch)
tree9cab633f2546a86e687fdefda75ab1bc24c17be3 /src/users.cpp
parent62d4c43612c617eafd1a11fdf7d1778b64682812 (diff)
Fixed <link> tags
Stability fixes/bounds checks UDP tunneling working for server->server git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@350 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/users.cpp')
-rw-r--r--src/users.cpp19
1 files changed, 12 insertions, 7 deletions
diff --git a/src/users.cpp b/src/users.cpp
index b179fabdd..4a9ada90d 100644
--- a/src/users.cpp
+++ b/src/users.cpp
@@ -50,11 +50,14 @@ bool userrec::IsInvited(char* channel)
{
for (InvitedList::iterator i = invites.begin(); i != invites.end(); i++)
{
- if (!strcasecmp(i->channel,channel))
- {
- return true;
+ if (i->channel) {
+ if (!strcasecmp(i->channel,channel))
+ {
+ return true;
+ }
}
}
+ return false;
}
void userrec::InviteTo(char* channel)
@@ -68,10 +71,12 @@ void userrec::RemoveInvite(char* channel)
{
for (InvitedList::iterator i = invites.begin(); i != invites.end(); i++)
{
- if (!strcasecmp(i->channel,channel))
- {
- invites.erase(i);
- return;
+ if (i->channel) {
+ if (!strcasecmp(i->channel,channel))
+ {
+ invites.erase(i);
+ return;
+ }
}
}
}