diff --git a/src/kit/shell/src/shellCheck.c b/src/kit/shell/src/shellCheck.c index 7fc8b1409a7602df48108d0e7f4763da48ed6497..bf73cdfa1324855ece7e69d1095bca862605bd23 100644 --- a/src/kit/shell/src/shellCheck.c +++ b/src/kit/shell/src/shellCheck.c @@ -193,9 +193,11 @@ void shellCheck(TAOS *con, SShellArguments *_args) { return; } - fprintf(stdout, "total %d tables will be checked by %d threads\n", tbNum, _args->threadNum); - shellRunCheckThreads(con, _args); - + if (tbNum > 0) { + fprintf(stdout, "total %d tables will be checked by %d threads\n", tbNum, _args->threadNum); + shellRunCheckThreads(con, _args); + } + int64_t end = taosGetTimestampMs(); fprintf(stdout, "total %d tables checked, failed:%d, time spent %.2f seconds\n", checkedNum, errorNum, (end - start) / 1000.0);