提交 2e2e8bea 编写于 作者: F fang

solve static check questions

上级 b93b8686
...@@ -1314,8 +1314,10 @@ int32_t tscLocalDoReduce(SSqlObj *pSql) { ...@@ -1314,8 +1314,10 @@ int32_t tscLocalDoReduce(SSqlObj *pSql) {
tscTrace("%s call the drop local reducer", __FUNCTION__); tscTrace("%s call the drop local reducer", __FUNCTION__);
tscDestroyLocalReducer(pSql); tscDestroyLocalReducer(pSql);
pRes->numOfRows = 0; if (pRes) {
pRes->row = 0; pRes->numOfRows = 0;
pRes->row = 0;
}
return 0; return 0;
} }
......
...@@ -2312,6 +2312,7 @@ int tscBuildCreateTableMsg(SSqlObj *pSql) { ...@@ -2312,6 +2312,7 @@ int tscBuildCreateTableMsg(SSqlObj *pSql) {
size = tscEstimateCreateTableMsgLength(pSql); size = tscEstimateCreateTableMsgLength(pSql);
if (TSDB_CODE_SUCCESS != tscAllocPayload(pCmd, size)) { if (TSDB_CODE_SUCCESS != tscAllocPayload(pCmd, size)) {
tscError("%p failed to malloc for create table msg", pSql); tscError("%p failed to malloc for create table msg", pSql);
free(tmpData);
return -1; return -1;
} }
......
...@@ -230,7 +230,7 @@ static int taos_options_imp(TSDB_OPTION option, const char *pStr) { ...@@ -230,7 +230,7 @@ static int taos_options_imp(TSDB_OPTION option, const char *pStr) {
return -1; return -1;
} }
if (cfg && cfg && cfg->cfgStatus <= TSDB_CFG_CSTATUS_OPTION) { if (cfg && cfg->cfgStatus <= TSDB_CFG_CSTATUS_OPTION) {
char sep = '.'; char sep = '.';
if (strlen(tsLocale) == 0) { // locale does not set yet if (strlen(tsLocale) == 0) { // locale does not set yet
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册