Merge pull request #18527 from taosdata/fix/TD-20667-3.0

fix(query): memory leak with pPageIdList on sort
This commit is contained in:
dapan1121 2022-11-29 12:08:41 +08:00 committed by GitHub
commit d3bf2c3abb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 2 deletions

View File

@ -116,9 +116,12 @@ void tsortClearOrderdSource(SArray *pOrderedSource) {
if (NULL == *pSource) {
continue;
}
// release pageIdList
if ((*pSource)->pageIdList) {
taosArrayDestroy((*pSource)->pageIdList);
}
if ((*pSource)->param && !(*pSource)->onlyRef) {
taosMemoryFree((*pSource)->param);
taosMemoryFree((*pSource)->param);
}
taosMemoryFreeClear(*pSource);
}