[TD-5134]<fix> fix runtime error

This commit is contained in:
yihaoDeng 2021-07-10 11:04:42 +08:00
parent 286f95756a
commit 5a7917e69b
1 changed files with 8 additions and 1 deletions

View File

@ -3363,9 +3363,16 @@ static int32_t doExtractColumnFilterInfo(SSqlCmd* pCmd, SQueryInfo* pQueryInfo,
int32_t bufLen = 0;
if (IS_NUMERIC_TYPE(pRight->value.nType)) {
bufLen = 60;
} else {
/*
* make memory sanitizer happy;
*/
if (pRight->value.nLen == 0) {
bufLen = pRight->value.nLen + 2;
} else {
bufLen = pRight->value.nLen + 1;
}
}
if (pExpr->tokenId == TK_LE || pExpr->tokenId == TK_LT) {
retVal = tVariantDump(&pRight->value, (char*)&pColumnFilter->upperBndd, colType, false);