fix(query):remove invalid destroy appinst operation.
This commit is contained in:
parent
aba4165f4b
commit
a693b9a2d6
|
@ -231,10 +231,9 @@ void destroyTscObj(void *pObj) {
|
|||
tscDebug("connObj 0x%" PRIx64 " p:%p destroyed, remain inst totalConn:%" PRId64, pTscObj->id, pTscObj,
|
||||
pTscObj->pAppInfo->numOfConns);
|
||||
|
||||
int64_t connNum = atomic_sub_fetch_64(&pTscObj->pAppInfo->numOfConns, 1);
|
||||
if (0 == connNum) {
|
||||
destroyAppInst(pTscObj->pAppInfo);
|
||||
}
|
||||
// In any cases, we should not free app inst here. Or an race condition rise.
|
||||
/*int64_t connNum = */atomic_sub_fetch_64(&pTscObj->pAppInfo->numOfConns, 1);
|
||||
|
||||
taosThreadMutexDestroy(&pTscObj->mutex);
|
||||
taosMemoryFree(pTscObj);
|
||||
|
||||
|
|
Loading…
Reference in New Issue