From 231cc9395ad45133634d81ae940f70e1dbe0a3c2 Mon Sep 17 00:00:00 2001 From: pk910 Date: Sat, 7 Jan 2012 01:41:05 +0100 Subject: [PATCH] don't show sub-sub-commands in linker overview --- src/modcmd.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/modcmd.c b/src/modcmd.c index 78b04c8..18483ed 100644 --- a/src/modcmd.c +++ b/src/modcmd.c @@ -170,6 +170,7 @@ static struct cmd_binding *modcmd_linker_command(struct ClientSocket *client, st int subcompos = 0; for(cbind = cmd_binds[bind_index]; cbind; cbind = cbind->next) { if(cbind->botid == client->botid && (cbind->botid || cbind->clientid == client->clientid) && stricmplen(cbind->cmd, command, commandlen) == 0) { + if(strstr(cbind->cmd + commandlen, " ")) continue; //ignore if there is another space in the command (sub-sub-command :D) subcompos += sprintf(subcommands + subcompos, (subcompos ? ", %s" : "%s"), cbind->cmd + commandlen); } } -- 2.20.1