From: pk910 Date: Sat, 7 Jan 2012 00:41:05 +0000 (+0100) Subject: don't show sub-sub-commands in linker overview X-Git-Tag: v5.3~75 X-Git-Url: http://git.pk910.de/?p=NeonServV5.git;a=commitdiff_plain;h=231cc9395ad45133634d81ae940f70e1dbe0a3c2 don't show sub-sub-commands in linker overview --- 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); } }