fix: release obj reference

This commit is contained in:
factosea 2024-02-05 15:18:09 +08:00
parent 5c7f839da8
commit 6c9bfb8f62
2 changed files with 6 additions and 2 deletions

View File

@ -52,8 +52,10 @@ void sqlReqLog(int64_t rid, bool killed, int32_t code) {
if (pTscObj != NULL) {
if (pTscObj->pAppInfo == NULL) {
tscLog("sqlReqLog, not found pAppInfo");
} else {
clientSQLReqLog(pTscObj->pAppInfo->instKey, pTscObj->user, result);
}
return clientSQLReqLog(pTscObj->pAppInfo->instKey, pTscObj->user, result);
releaseTscObj(rid);
} else {
tscLog("sqlReqLog, not found rid");
}

View File

@ -69,8 +69,10 @@ void SlowQueryLog(int64_t rid, bool killed, int32_t code, int32_t cost) {
if (pTscObj != NULL) {
if(pTscObj->pAppInfo == NULL) {
tscLog("SlowQueryLog, not found pAppInfo");
} else {
clientSlowQueryLog(pTscObj->pAppInfo->instKey, pTscObj->user, result, cost);
}
return clientSlowQueryLog(pTscObj->pAppInfo->instKey, pTscObj->user, result, cost);
releaseTscObj(rid);
} else {
tscLog("SlowQueryLog, not found rid");
}