From 360d59428c4b74069c9760feedbff1f16048ba66 Mon Sep 17 00:00:00 2001 From: SunShine Chan Date: Fri, 25 Jun 2021 14:20:39 +0800 Subject: [PATCH] [TD-4902] FIX -m parameter of taosdemo with letter-initial string (#6620) * [TD-4902] FIX with 1 char * Fix prompt of -m @ taosdemo --- src/kit/taosdemo/taosdemo.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/kit/taosdemo/taosdemo.c b/src/kit/taosdemo/taosdemo.c index 38f0ecb219..0eac1518a7 100644 --- a/src/kit/taosdemo/taosdemo.c +++ b/src/kit/taosdemo/taosdemo.c @@ -982,9 +982,9 @@ static void parse_args(int argc, char *argv[], SArguments *arguments) { arguments->len_of_binary = atoi(argv[++i]); } else if (strcmp(argv[i], "-m") == 0) { if ((argc == i+1) || - (!isStringNumber(argv[i+1]))) { + (isStringNumber(argv[i+1]))) { printHelp(); - errorPrint("%s", "\n\t-m need a number following!\n"); + errorPrint("%s", "\n\t-m need a letter-initial string following!\n"); exit(EXIT_FAILURE); } arguments->tb_prefix = argv[++i]; -- GitLab