Zoltan Borok-Nagy has posted comments on this change. ( http://gerrit.cloudera.org:8080/20723 )
Change subject: IMPALA-12571: Fix errors related to small strings found by Clang sanitizer builds ...................................................................... Patch Set 3: (1 comment) Thanks for the comment! http://gerrit.cloudera.org:8080/#/c/20723/2/be/src/runtime/string-value.cc File be/src/runtime/string-value.cc: http://gerrit.cloudera.org:8080/#/c/20723/2/be/src/runtime/string-value.cc@39 PS2, Line 39: const char* ptr = Ptr(); > Could this be const? Also I'm not clear what issue this is fixing. Sure, this can be const. This doesn't fix the bug, the stack-use-after-scope bug was in string-value-test because of the temporary std::strings. But the ASAN error pointed to this line, so I just experimented here then kept this change anyway, so we can be sure we don't do anything unnecessary in the loop. -- To view, visit http://gerrit.cloudera.org:8080/20723 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: I51d48b79bde0a5ae0103a780f9c09f3003ed157e Gerrit-Change-Number: 20723 Gerrit-PatchSet: 3 Gerrit-Owner: Zoltan Borok-Nagy <[email protected]> Gerrit-Reviewer: Csaba Ringhofer <[email protected]> Gerrit-Reviewer: Daniel Becker <[email protected]> Gerrit-Reviewer: Impala Public Jenkins <[email protected]> Gerrit-Reviewer: Michael Smith <[email protected]> Gerrit-Reviewer: Zoltan Borok-Nagy <[email protected]> Gerrit-Comment-Date: Wed, 22 Nov 2023 22:02:22 +0000 Gerrit-HasComments: Yes
