提交 9ca13303 authored 作者: Ken Rice's avatar Ken Rice

FS-9222 small tweak to freeswitch console to strip leading spaces from commands

上级 d5e390ab
......@@ -352,7 +352,7 @@ SWITCH_DECLARE(switch_status_t) switch_console_execute(char *xcmd, int rec, swit
int argc;
char *argv[128];
int x;
char *dup = strdup(xcmd);
char *dup = NULL;
char *cmd;
switch_status_t status = SWITCH_STATUS_FALSE;
......@@ -363,6 +363,10 @@ SWITCH_DECLARE(switch_status_t) switch_console_execute(char *xcmd, int rec, swit
goto end;
}
while (*xcmd == ' ') xcmd++;
dup = strdup(xcmd);
if (!strncasecmp(xcmd, "alias", 5)) {
argc = 1;
argv[0] = xcmd;
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论