[fix bug]
This commit is contained in:
parent
92cd048474
commit
3cc384a03c
|
@ -297,7 +297,7 @@ static void doInitGlobalConfig() {
|
|||
SGlobalCfg cfg = {0};
|
||||
|
||||
// ip address
|
||||
cfg.option = "first";
|
||||
cfg.option = "firstEp";
|
||||
cfg.ptr = tsFirst;
|
||||
cfg.valType = TAOS_CFG_VTYPE_STRING;
|
||||
cfg.cfgType = TSDB_CFG_CTYPE_B_CONFIG | TSDB_CFG_CTYPE_B_CLIENT;
|
||||
|
@ -307,7 +307,7 @@ static void doInitGlobalConfig() {
|
|||
cfg.unitType = TAOS_CFG_UTYPE_NONE;
|
||||
taosInitConfigOption(cfg);
|
||||
|
||||
cfg.option = "second";
|
||||
cfg.option = "secondEp";
|
||||
cfg.ptr = tsSecond;
|
||||
cfg.valType = TAOS_CFG_VTYPE_STRING;
|
||||
cfg.cfgType = TSDB_CFG_CTYPE_B_CONFIG | TSDB_CFG_CTYPE_B_CLIENT;
|
||||
|
|
|
@ -73,6 +73,8 @@ TAOS *shellInit(SShellArguments *args) {
|
|||
// Connect to the database.
|
||||
TAOS *con = taos_connect(args->host, args->user, args->password, args->database, args->port);
|
||||
if (con == NULL) {
|
||||
printf("taos connect failed, reason: %s.\n\n", tstrerror(terrno));
|
||||
fflush(stdout);
|
||||
return con;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue