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

Merge pull request #9821 from taosdata/fix/TS-1105

[TS-1105]<hotfix>(other): fix core dump when setLocale on windows
...@@ -397,6 +397,10 @@ static int taos_options_imp(TSDB_OPTION option, const char *pStr) { ...@@ -397,6 +397,10 @@ static int taos_options_imp(TSDB_OPTION option, const char *pStr) {
cfg->cfgStatus = TAOS_CFG_CSTATUS_OPTION; cfg->cfgStatus = TAOS_CFG_CSTATUS_OPTION;
} else { // set the user specified locale failed, use default LC_CTYPE as current locale } else { // set the user specified locale failed, use default LC_CTYPE as current locale
locale = setlocale(LC_CTYPE, tsLocale); locale = setlocale(LC_CTYPE, tsLocale);
if (locale == NULL) {
tscError("failed to set locale:%s failed, neither default LC_CTYPE: %s", pStr, tsLocale);
return -1;
}
tscInfo("failed to set locale:%s, current locale:%s", pStr, tsLocale); tscInfo("failed to set locale:%s, current locale:%s", pStr, tsLocale);
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册