X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=include%2Fu_listmode.h;h=69ee4f668db7cc20097bea1b1758fca4853cc034;hb=484b718ccf1505360d62401dd09e3eca6b2568d8;hp=390a8729b444f4b4b8b5f022c657080bec4ad832;hpb=cc07a20aa29bfa7bf23f3cd99b97929882113328;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/include/u_listmode.h b/include/u_listmode.h index 390a8729b..69ee4f668 100644 --- a/include/u_listmode.h +++ b/include/u_listmode.h @@ -521,12 +521,13 @@ class ListModeBase : public ModeHandler { if (LM->extban && it->mask.length() > 1 && it->mask[0] == LM->extban && it->mask[1] == ':') { + static std::string ext = it->mask.substr(2); if (LM->user) { - if (InspIRCd::Match(LM->user->GetFullRealHost(), it->mask.substr(2)) || InspIRCd::Match(LM->user->GetFullHost(), it->mask.substr(2)) || (InspIRCd::MatchCIDR(LM->literal, it->mask.substr(2)))) + 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, it->mask.substr(2))) + else if (InspIRCd::Match(LM->literal, ext)) return it->mask.c_str(); } else