提交 aa5845ec 编写于 作者: sangshuduo's avatar sangshuduo

move few lines pSupporter initilization code ahead to make easier cleanup.

上级 c0177620
......@@ -654,26 +654,23 @@ void *vnodeQueryOnSingleTable(SMeterObj **pMetersObj, SSqlGroupbyExpr *pGroupbyE
goto _error;
}
pSupporter->numOfMeters = 1;
pSupporter->pSidSet = NULL;
pSupporter->subgroupIdx = -1;
pSupporter->pMeterSidExtInfo = NULL;
pQInfo->pTableQuerySupporter = pSupporter;
pSupporter->pMetersHashTable = taosInitHashTable(pSupporter->numOfMeters, taosIntHash_32, false);
if (pSupporter->pMetersHashTable == NULL) {
tfree(pSupporter);
*code = TSDB_CODE_SERV_OUT_OF_MEMORY;
goto _error;
}
if (taosAddToHashTable(pSupporter->pMetersHashTable, (const char*) &pMetersObj[0]->sid, sizeof(pMeterObj[0].sid),
(char *)&pMetersObj[0], POINTER_BYTES) != 0) {
tfree(pSupporter);
*code = TSDB_CODE_APP_ERROR;
goto _error;
}
pSupporter->pSidSet = NULL;
pSupporter->subgroupIdx = -1;
pSupporter->pMeterSidExtInfo = NULL;
pQInfo->pTableQuerySupporter = pSupporter;
STSBuf *pTSBuf = NULL;
if (pQueryMsg->tsLen > 0) {
// open new file to save the result
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册