summaryrefslogtreecommitdiff
path: root/src/commands/cmd_commands.cpp
diff options
context:
space:
mode:
authorattilamolnar <attilamolnar@hush.com>2012-07-11 00:45:22 +0200
committerattilamolnar <attilamolnar@hush.com>2012-07-11 00:56:10 +0200
commit655387286ab0517c9cdb905d67fad74f80cda241 (patch)
treedc9ef6bec3faeae8044bdeb4f06924fc676541d2 /src/commands/cmd_commands.cpp
parent6735f2da27df23ee34936a4b17727f4ba44c04e8 (diff)
cmd_commands Don't show server only commands to users
Diffstat (limited to 'src/commands/cmd_commands.cpp')
-rw-r--r--src/commands/cmd_commands.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/commands/cmd_commands.cpp b/src/commands/cmd_commands.cpp
index 13bd3fab8..36408b363 100644
--- a/src/commands/cmd_commands.cpp
+++ b/src/commands/cmd_commands.cpp
@@ -48,6 +48,10 @@ CmdResult CommandCommands::Handle (const std::vector<std::string>&, User *user)
list.reserve(ServerInstance->Parser->cmdlist.size());
for (Commandtable::iterator i = ServerInstance->Parser->cmdlist.begin(); i != ServerInstance->Parser->cmdlist.end(); i++)
{
+ // Don't show S2S commands to users
+ if (i->second->flags_needed == FLAG_SERVERONLY)
+ continue;
+
Module* src = i->second->creator;
char buffer[MAXBUF];
snprintf(buffer, MAXBUF, ":%s %03d %s :%s %s %d %d",