[ https://issues.apache.org/jira/browse/IMPALA-8713?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16874690#comment-16874690 ]
ASF subversion and git services commented on IMPALA-8713: --------------------------------------------------------- Commit c353cf7a648651244ac39677d0cb028e704281d0 in impala's branch refs/heads/master from Tim Armstrong [ https://gitbox.apache.org/repos/asf?p=impala.git;h=c353cf7 ] IMPALA-8713: fix stack overflow in unhex() Write the results into the output heap buffer instead of into a temporary stack buffer. No additional memory is used because AnyValUtil::FromBuffer() allocated a temporary buffer anyway. Testing: Added a targeted test to expr-test that caused a crash before this fix. Change-Id: Ie0c1760511a04c0823fc465cf6e529e9681b2488 Reviewed-on: http://gerrit.cloudera.org:8080/13743 Reviewed-by: Impala Public Jenkins <impala-public-jenk...@cloudera.com> Tested-by: Impala Public Jenkins <impala-public-jenk...@cloudera.com> > MathFunctions::Unhex() can overflow stack > ----------------------------------------- > > Key: IMPALA-8713 > URL: https://issues.apache.org/jira/browse/IMPALA-8713 > Project: IMPALA > Issue Type: Bug > Components: Backend > Affects Versions: Impala 3.2.0 > Reporter: Tim Armstrong > Assignee: Tim Armstrong > Priority: Blocker > Labels: crash > > It allocates a stack buffer large enough to hold the output string. It > shouldn't be hard to see what could go wrong. E.g. > {code} > select unhex(repeat('z', 1024 * 1024 * 1024)) > {code} -- This message was sent by Atlassian JIRA (v7.6.3#76005) --------------------------------------------------------------------- To unsubscribe, e-mail: issues-all-unsubscr...@impala.apache.org For additional commands, e-mail: issues-all-h...@impala.apache.org