fix: memory leak while subscribe

This commit is contained in:
Shengliang Guan 2022-11-27 21:27:15 +08:00
parent 56ccb65c3e
commit c4045de4bb
2 changed files with 4 additions and 0 deletions

View File

@ -585,6 +585,8 @@ int32_t mndSchedInitSubEp(SMnode* pMnode, const SMqTopicObj* pTopic, SMqSubscrib
} else {
pVgEp->qmsg = strdup("");
}
sdbRelease(pSdb, pVgroup);
}
ASSERT(pSub->unassignedVgs->size > 0);

View File

@ -512,6 +512,8 @@ static int32_t mndCreateTopic(SMnode *pMnode, SRpcMsg *pReq, SCMCreateTopicReq *
mndTransDrop(pTrans);
return -1;
}
sdbRelease(pSdb, pVgroup);
}
}