未验证 提交 c7975e6b 编写于 作者: M Minglei Jin 提交者: GitHub

Merge pull request #11414 from taosdata/fix/TS-1409

fix(shell): print taos_connect failed reason befor exiting
...@@ -224,6 +224,8 @@ TAOS *taos_connect_internal(const char *ip, const char *user, const char *pass, ...@@ -224,6 +224,8 @@ TAOS *taos_connect_internal(const char *ip, const char *user, const char *pass,
} }
} }
printf("connect failed, reason: %s\n\n", taos_errstr(pSql));
return NULL; return NULL;
} }
......
...@@ -87,7 +87,6 @@ TAOS *shellInit(SShellArguments *_args) { ...@@ -87,7 +87,6 @@ TAOS *shellInit(SShellArguments *_args) {
} }
if (con == NULL) { if (con == NULL) {
printf("\033[31mfailed to connect to db, reason:%s\033[0m\n", taos_errstr(con));
fflush(stdout); fflush(stdout);
return con; return con;
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册