Yida Wu has uploaded a new patch set (#2). ( 
http://gerrit.cloudera.org:8080/22632 )

Change subject: IMPALA-13868: Fix ASAN build failed in 
test_ai_generate_text_exprs
......................................................................

IMPALA-13868: Fix ASAN build failed in test_ai_generate_text_exprs

In ParseImpalaOptions(), when the input options cannot be parsed,
the error message is constructed incorrectly by directly using the
StringVal pointer without considering its length. This may result
in reading beyond the allocated memory, leading to unexpected
behavior.

This issue was introduced by IMPALA-13565 and triggered ASAN
errors due to new test cases added in IMPALA-13812
(query_test/test_exprs.py). While IMPALA-13565 included unit
tests (AiFunctionsTest in expr-test.cc) for this code, the
newly added ee tests test_ai_generate_text_exprs() in
IMPALA-13812 run in parallel, making it much easier to trigger
this issue.

The patch fixes the issue by ensuring the error message is
constructed using both the pointer and its length.

Tests:
Passed the ASAN build tests.

Change-Id: I9f4656e256bb9b31acc2653c3b910788ddf03f2b
---
M be/src/exprs/ai-functions.cc
1 file changed, 2 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/32/22632/2
--
To view, visit http://gerrit.cloudera.org:8080/22632
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I9f4656e256bb9b31acc2653c3b910788ddf03f2b
Gerrit-Change-Number: 22632
Gerrit-PatchSet: 2
Gerrit-Owner: Yida Wu <[email protected]>
Gerrit-Reviewer: Abhishek Rawat <[email protected]>
Gerrit-Reviewer: Impala Public Jenkins <[email protected]>
Gerrit-Reviewer: Riza Suminto <[email protected]>

Reply via email to