From 5e6a1fed781eb5e31ff7d2c3446839ec8a3c5072 Mon Sep 17 00:00:00 2001 From: Dmitry Podgorny Date: Fri, 16 Nov 2012 13:44:15 +0200 Subject: [PATCH] _cmd_tiny: fix allocation for usage variable --- src/command.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/command.c b/src/command.c index 609b3817..b9c77b10 100644 --- a/src/command.c +++ b/src/command.c @@ -1301,7 +1301,7 @@ _cmd_tiny(const char * const inp, struct cmd_help_t help) if (args == NULL) { cons_show("Usage: %s", help.usage); if (win_in_chat()) { - char usage[strlen(help.usage + 8)]; + char usage[strlen(help.usage) + 8]; sprintf(usage, "Usage: %s", help.usage); win_show(usage); }