提交 6679b8af 编写于 作者: B Benguang Zhao

fix: release action.pCont on error

上级 267cbfbc
...@@ -263,6 +263,7 @@ static int32_t mndTransDecodeAction(SSdbRaw *pRaw, int32_t *offset, SArray *pAct ...@@ -263,6 +263,7 @@ static int32_t mndTransDecodeAction(SSdbRaw *pRaw, int32_t *offset, SArray *pAct
_OVER: _OVER:
*offset = dataPos; *offset = dataPos;
taosMemoryFreeClear(action.pCont);
return ret; return ret;
} }
...@@ -279,7 +280,6 @@ static SSdbRow *mndTransDecode(SSdbRaw *pRaw) { ...@@ -279,7 +280,6 @@ static SSdbRow *mndTransDecode(SSdbRaw *pRaw) {
int32_t undoActionNum = 0; int32_t undoActionNum = 0;
int32_t commitActionNum = 0; int32_t commitActionNum = 0;
int32_t dataPos = 0; int32_t dataPos = 0;
STransAction action = {0};
if (sdbGetRawSoftVer(pRaw, &sver) != 0) goto _OVER; if (sdbGetRawSoftVer(pRaw, &sver) != 0) goto _OVER;
...@@ -360,7 +360,6 @@ _OVER: ...@@ -360,7 +360,6 @@ _OVER:
mError("trans:%d, failed to parse from raw:%p since %s", pTrans->id, pRaw, terrstr()); mError("trans:%d, failed to parse from raw:%p since %s", pTrans->id, pRaw, terrstr());
mndTransDropData(pTrans); mndTransDropData(pTrans);
taosMemoryFreeClear(pRow); taosMemoryFreeClear(pRow);
taosMemoryFreeClear(action.pCont);
return NULL; return NULL;
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册