fix:double free error for parserTest
This commit is contained in:
parent
3b4c2826b4
commit
e9accd26df
|
@ -1989,6 +1989,7 @@ static FORCE_INLINE void tdDestroySVCreateTbReq(SVCreateTbReq* req) {
|
||||||
taosMemoryFreeClear(req->ctb.pTag);
|
taosMemoryFreeClear(req->ctb.pTag);
|
||||||
taosMemoryFreeClear(req->ctb.name);
|
taosMemoryFreeClear(req->ctb.name);
|
||||||
taosArrayDestroy(req->ctb.tagName);
|
taosArrayDestroy(req->ctb.tagName);
|
||||||
|
req->ctb.tagName = NULL;
|
||||||
} else if (req->type == TSDB_NORMAL_TABLE) {
|
} else if (req->type == TSDB_NORMAL_TABLE) {
|
||||||
taosMemoryFreeClear(req->ntb.schemaRow.pSchema);
|
taosMemoryFreeClear(req->ntb.schemaRow.pSchema);
|
||||||
}
|
}
|
||||||
|
|
|
@ -1514,6 +1514,7 @@ int32_t parseInsertSql(SParseContext* pContext, SQuery** pQuery, SParseMetaCache
|
||||||
.pSql = (char*)pContext->pSql,
|
.pSql = (char*)pContext->pSql,
|
||||||
.msg = {.buf = pContext->pMsg, .len = pContext->msgLen},
|
.msg = {.buf = pContext->pMsg, .len = pContext->msgLen},
|
||||||
.pTableMeta = NULL,
|
.pTableMeta = NULL,
|
||||||
|
.createTblReq = {0},
|
||||||
.pSubTableHashObj = taosHashInit(128, taosGetDefaultHashFunction(TSDB_DATA_TYPE_VARCHAR), true, HASH_NO_LOCK),
|
.pSubTableHashObj = taosHashInit(128, taosGetDefaultHashFunction(TSDB_DATA_TYPE_VARCHAR), true, HASH_NO_LOCK),
|
||||||
.pTableNameHashObj = taosHashInit(128, taosGetDefaultHashFunction(TSDB_DATA_TYPE_VARCHAR), true, HASH_NO_LOCK),
|
.pTableNameHashObj = taosHashInit(128, taosGetDefaultHashFunction(TSDB_DATA_TYPE_VARCHAR), true, HASH_NO_LOCK),
|
||||||
.pDbFNameHashObj = taosHashInit(64, taosGetDefaultHashFunction(TSDB_DATA_TYPE_VARCHAR), true, HASH_NO_LOCK),
|
.pDbFNameHashObj = taosHashInit(64, taosGetDefaultHashFunction(TSDB_DATA_TYPE_VARCHAR), true, HASH_NO_LOCK),
|
||||||
|
|
Loading…
Reference in New Issue