Merge pull request #18256 from taosdata/fix/TD-20504

fix: fix asan issue
This commit is contained in:
dapan1121 2022-11-18 13:27:20 +08:00 committed by GitHub
commit 3de853ed61
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 7 additions and 3 deletions

View File

@ -3248,14 +3248,18 @@ bool filterExecuteImpl(void *pinfo, int32_t numOfRows, SColumnInfoData *pRes, SC
for (uint32_t u = 0; u < group->unitNum; ++u) {
uint32_t uidx = group->unitIdxs[u];
SFilterComUnit *cunit = &info->cunits[uidx];
void *colData = colDataGetData((SColumnInfoData *)(cunit->colData), i);
void *colData = NULL;
bool isNull = colDataIsNull((SColumnInfoData *)(cunit->colData), 0, i, NULL);
// if (FILTER_UNIT_GET_F(info, uidx)) {
// p[i] = FILTER_UNIT_GET_R(info, uidx);
// } else {
uint8_t optr = cunit->optr;
if (colData == NULL || colDataIsNull((SColumnInfoData *)(cunit->colData), 0, i, NULL)) {
if (!isNull) {
colData = colDataGetData((SColumnInfoData *)(cunit->colData), i);
}
if (colData == NULL || isNull) {
p[i] = optr == OP_TYPE_IS_NULL ? true : false;
} else {
if (optr == OP_TYPE_IS_NOT_NULL) {