From df4f3cb30224e7d041d90309fcfdb137da792540 Mon Sep 17 00:00:00 2001 From: Johan Wikman Date: Tue, 26 Sep 2017 13:47:08 +0300 Subject: [PATCH] MXS-1450 Remove leading whitespace Leading whitespace is removed from a sent maxadmin command before the command is interpreted. --- server/modules/routing/debugcli/debugcmd.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/server/modules/routing/debugcli/debugcmd.c b/server/modules/routing/debugcli/debugcmd.c index 7010746db..922456635 100644 --- a/server/modules/routing/debugcli/debugcmd.c +++ b/server/modules/routing/debugcli/debugcmd.c @@ -51,6 +51,7 @@ #include #include #include +#include #include #include @@ -1741,7 +1742,7 @@ execute_cmd(CLI_SESSION *cli) bool in_space = false; int nskip = 0; - args[0] = cli->cmdbuf; + args[0] = trim_leading(cli->cmdbuf); ptr = args[0]; lptr = ptr; i = 1;