fix: fix mem leak
This commit is contained in:
parent
892d7861f0
commit
6e561a6c78
|
@ -1369,7 +1369,7 @@ int32_t doProcessMsgFromServer(void* param) {
|
|||
updateTargetEpSet(pSendInfo, pTscObj, pMsg, pEpSet);
|
||||
|
||||
SDataBuf buf = {
|
||||
.msgType = pMsg->msgType, .len = pMsg->contLen, .pData = NULL, .handle = pMsg->info.handle, .pEpSet = NULL};
|
||||
.msgType = pMsg->msgType, .len = pMsg->contLen, .pData = NULL, .handle = pMsg->info.handle, .pEpSet = pEpSet};
|
||||
|
||||
if (pMsg->contLen > 0) {
|
||||
buf.pData = taosMemoryCalloc(1, pMsg->contLen);
|
||||
|
@ -1385,7 +1385,6 @@ int32_t doProcessMsgFromServer(void* param) {
|
|||
rpcFreeCont(pMsg->pCont);
|
||||
destroySendMsgInfo(pSendInfo);
|
||||
|
||||
taosMemoryFree(arg->pEpset);
|
||||
taosMemoryFree(arg);
|
||||
return TSDB_CODE_SUCCESS;
|
||||
}
|
||||
|
|
|
@ -323,10 +323,6 @@ static int32_t tfSearchCompareFunc(void* reader, SIndexTerm* tem, SIdxTRslt* tr,
|
|||
while ((rt = stmStNextWith(st, NULL)) != NULL) {
|
||||
FstSlice* s = &rt->data;
|
||||
char* ch = (char*)fstSliceData(s, NULL);
|
||||
// if (0 != strncmp(ch, tem->colName, tem->nColName)) {
|
||||
// swsResultDestroy(rt);
|
||||
// break;
|
||||
//}
|
||||
|
||||
TExeCond cond = cmpFn(ch, p, tem->colType);
|
||||
if (MATCH == cond) {
|
||||
|
|
|
@ -430,12 +430,14 @@ int32_t schHandleRedirect(SSchJob *pJob, SSchTask *pTask, SDataBuf *pData, int32
|
|||
|
||||
code = schDoTaskRedirect(pJob, pTask, pData, rspCode);
|
||||
taosMemoryFree(pData->pData);
|
||||
taosMemoryFree(pData->pEpSet);
|
||||
|
||||
SCH_RET(code);
|
||||
|
||||
_return:
|
||||
|
||||
taosMemoryFree(pData->pData);
|
||||
taosMemoryFree(pData->pEpSet);
|
||||
|
||||
SCH_RET(schProcessOnTaskFailure(pJob, pTask, code));
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue