summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorw00t <w00t@e03df62e-2008-0410-955e-edbf42e46eb7>2009-01-23 10:16:51 +0000
committerw00t <w00t@e03df62e-2008-0410-955e-edbf42e46eb7>2009-01-23 10:16:51 +0000
commit5f5ed857af365f963cfe2534700a03c862ea3354 (patch)
tree39d251655e66b52f9793b7c6edb1707af83594cc /include
parent9bb31e58f8dfebd3c7297e738886f94c7bb3196b (diff)
Fix bug 688, reported by Ankit: extended invexes don't work correctly at all. Thanks very much for your help tracking this down :)
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@10988 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'include')
-rw-r--r--include/u_listmode.h13
1 files changed, 12 insertions, 1 deletions
diff --git a/include/u_listmode.h b/include/u_listmode.h
index 97a6243e5..666e851f7 100644
--- a/include/u_listmode.h
+++ b/include/u_listmode.h
@@ -512,33 +512,44 @@ class ListModeBase : public ModeHandler
{
modelist* mlist;
LM->chan->GetExt(GetInfoKey(), mlist);
+
if (mlist)
{
if (LM->user)
+ {
LM->literal = LM->user->nick + "!" + LM->user->ident + "@" + LM->user->GetIPString();
+ }
for (modelist::iterator it = mlist->begin(); it != mlist->end(); it++)
{
if (LM->extban && it->mask.length() > 1 && it->mask[0] == LM->extban && it->mask[1] == ':')
{
- static std::string ext = it->mask.substr(2);
+ std::string ext = it->mask.substr(2);
if (LM->user)
{
if (InspIRCd::Match(LM->user->GetFullRealHost(), ext) || InspIRCd::Match(LM->user->GetFullHost(), ext) || (InspIRCd::MatchCIDR(LM->literal, ext)))
+ {
return it->mask.c_str();
+ }
}
else if (InspIRCd::Match(LM->literal, ext))
+ {
return it->mask.c_str();
+ }
}
else
{
if (LM->user)
{
if (InspIRCd::Match(LM->user->GetFullRealHost(), it->mask) || InspIRCd::Match(LM->user->GetFullHost(), it->mask) || (InspIRCd::MatchCIDR(LM->literal, it->mask)))
+ {
return it->mask.c_str();
+ }
}
else if (InspIRCd::Match(LM->literal, it->mask))
+ {
return it->mask.c_str();
+ }
}
}
}