From 6cadb9dfa186493ae1331c70cc36fc95c78025dd Mon Sep 17 00:00:00 2001 From: Haojun Liao Date: Tue, 16 Mar 2021 16:17:42 +0800 Subject: [PATCH] [td-3331]: print timestamp format error. --- src/kit/shell/src/shellEngine.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/kit/shell/src/shellEngine.c b/src/kit/shell/src/shellEngine.c index a6f5869936..e86a1fce60 100644 --- a/src/kit/shell/src/shellEngine.c +++ b/src/kit/shell/src/shellEngine.c @@ -412,7 +412,7 @@ static char* formatTimestamp(char* buf, int64_t val, int precision) { #ifdef WINDOWS if (tt < 0) tt = 0; #endif - if (tt < 0 && ms != 0) { + if (tt <= 0 && ms < 0) { tt--; if (precision == TSDB_TIME_PRECISION_MICRO) { ms += 1000000; -- GitLab