[TD-225] release the ref if insertion succeeds.
This commit is contained in:
parent
aafb60988b
commit
af02383613
|
@ -407,7 +407,9 @@ void tscResetSqlCmdObj(SSqlCmd* pCmd, bool removeFromCache) {
|
|||
pCmd->autoCreated = 0;
|
||||
|
||||
for(int32_t i = 0; i < pCmd->numOfTables; ++i) {
|
||||
taosCacheRelease(tscMetaCache, (void**)&(pCmd->pTableMetaList[i]), false);
|
||||
if (pCmd->pTableMetaList[i] != NULL) {
|
||||
taosCacheRelease(tscMetaCache, (void**)&(pCmd->pTableMetaList[i]), false);
|
||||
}
|
||||
}
|
||||
|
||||
pCmd->numOfTables = 0;
|
||||
|
|
Loading…
Reference in New Issue