You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues-all@impala.apache.org by "Daniel Becker (Jira)" <ji...@apache.org> on 2023/10/16 15:50:00 UTC

[jira] [Commented] (IMPALA-12478) Invalid length in StringValue::LeastSmallerString()

    [ https://issues.apache.org/jira/browse/IMPALA-12478?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17775825#comment-17775825 ] 

Daniel Becker commented on IMPALA-12478:
----------------------------------------

https://gerrit.cloudera.org/#/c/20579/

> Invalid length in StringValue::LeastSmallerString()
> ---------------------------------------------------
>
>                 Key: IMPALA-12478
>                 URL: https://issues.apache.org/jira/browse/IMPALA-12478
>             Project: IMPALA
>          Issue Type: Bug
>          Components: Backend
>            Reporter: Daniel Becker
>            Assignee: Daniel Becker
>            Priority: Major
>
> In StringValue::LeastSmallerString() we do not check if 'len' is 0 before subtracting 1 from it. The resulting, possibly negative value is later used as the length of a new string.
> See [https://github.com/apache/impala/blob/ae14d78c8f2e8366e67aa8c39f0c02c60862905e/be/src/runtime/string-value.cc#L51]
> Also, the name of the function should actually be LargestSmallerString(), cf. LeastLargerString().



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-all-unsubscribe@impala.apache.org
For additional commands, e-mail: issues-all-help@impala.apache.org