[td-225]refactor code: remove useless codes

This commit is contained in:
Haojun Liao 2020-05-22 22:46:11 +08:00
parent 54890e4815
commit 95c97a5df8
1 changed files with 4 additions and 7 deletions

View File

@ -384,13 +384,10 @@ int tscProcessLocalCmd(SSqlObj *pSql) {
// keep the code in local variable in order to avoid invalid read in case of async query
int32_t code = pSql->res.code;
if (pSql->fp != NULL) { // callback function
if (code == 0) {
(*pSql->fp)(pSql->param, pSql, 0);
} else {
tscQueueAsyncRes(pSql);
}
if (code == TSDB_CODE_SUCCESS) {
(*pSql->fp)(pSql->param, pSql, 0);
} else {
tscQueueAsyncRes(pSql);
}
return code;