summaryrefslogtreecommitdiff
path: root/modules/commands/os_list.cpp
diff options
context:
space:
mode:
authorAdam <Adam@anope.org>2011-11-04 18:04:12 -0400
committerAdam <Adam@anope.org>2011-11-04 18:04:12 -0400
commitd01f4ea3ce7ff16409e9c21f0a6426958da40462 (patch)
tree5cf448d26ef11a1633abb06081d7a5949bc4c39e /modules/commands/os_list.cpp
parenta42cafbf69ac2753cb891f87664d1218b00a1bcf (diff)
Allow /os userlist to match host and ip too
Diffstat (limited to 'modules/commands/os_list.cpp')
-rw-r--r--modules/commands/os_list.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/commands/os_list.cpp b/modules/commands/os_list.cpp
index 45179a427..ccca1a617 100644
--- a/modules/commands/os_list.cpp
+++ b/modules/commands/os_list.cpp
@@ -137,8 +137,8 @@ class CommandOSUserList : public Command
if (!pattern.empty())
{
- Anope::string mask = u2->nick + "!" + u2->GetIdent() + "@" + u2->GetDisplayedHost();
- if (!Anope::Match(mask, pattern))
+ Anope::string mask = u2->nick + "!" + u2->GetIdent() + "@" + u2->GetDisplayedHost(), mask2 = u2->nick + "!" + u2->GetIdent() + "@" + u2->host, mask3 = u2->nick + "!" + u2->GetIdent() + "@" + (u2->ip() ? u2->ip.addr() : u2->host);
+ if (!Anope::Match(mask, pattern) && !Anope::Match(mask2, pattern) && !Anope::Match(mask3, pattern))
continue;
if (!Modes.empty())
for (std::list<UserModeName>::iterator mit = Modes.begin(), mit_end = Modes.end(); mit != mit_end; ++mit)