fix: mutex init for trans

This commit is contained in:
kailixu 2023-10-05 09:19:44 +08:00
parent 977dbe3018
commit c339f3552a
1 changed files with 2 additions and 0 deletions

View File

@ -543,6 +543,8 @@ STrans *mndAcquireTrans(SMnode *pMnode, int32_t transId) {
STrans *pTrans = sdbAcquire(pMnode->pSdb, SDB_TRANS, &transId);
if (pTrans == NULL) {
terrno = TSDB_CODE_MND_TRANS_NOT_EXIST;
} else {
taosThreadMutexInit(&pTrans->mutex, NULL);
}
return pTrans;
}