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

Merge pull request #13892 from taosdata/fix/TS-1594-2.4

fix: added upstream check to avoid crash
...@@ -4193,7 +4193,8 @@ void executeQuery(SSqlObj* pSql, SQueryInfo* pQueryInfo) { ...@@ -4193,7 +4193,8 @@ void executeQuery(SSqlObj* pSql, SQueryInfo* pQueryInfo) {
tscAddIntoSqlList(pSql); tscAddIntoSqlList(pSql);
} }
if (taosArrayGetSize(pQueryInfo->pUpstream) > 0) { // nest query. do execute it firstly // upstream may be freed before retry
if (pQueryInfo->pUpstream && taosArrayGetSize(pQueryInfo->pUpstream) > 0) { // nest query. do execute it firstly
code = doInitSubState(pSql, (int32_t) taosArrayGetSize(pQueryInfo->pUpstream)); code = doInitSubState(pSql, (int32_t) taosArrayGetSize(pQueryInfo->pUpstream));
if (code != TSDB_CODE_SUCCESS) { if (code != TSDB_CODE_SUCCESS) {
goto _error; goto _error;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册