Tim Armstrong has posted comments on this change. ( http://gerrit.cloudera.org:8080/12280 )
Change subject: IMPALA-5031: out-of-range enum values are undefined behavior ...................................................................... Patch Set 1: Code-Review+2 (2 comments) http://gerrit.cloudera.org:8080/#/c/12280/1/be/src/exec/parquet/parquet-metadata-utils.cc File be/src/exec/parquet/parquet-metadata-utils.cc: http://gerrit.cloudera.org:8080/#/c/12280/1/be/src/exec/parquet/parquet-metadata-utils.cc@216 PS1, Line 216: const auto codec = Ubsan::EnumToInt(&col_chunk_metadata.codec); Wouldn't we have already caused some kind of undefined behaviour earlier when the thrift decoding wrote the field? http://gerrit.cloudera.org:8080/#/c/12280/1/be/src/util/ubsan.h File be/src/util/ubsan.h: http://gerrit.cloudera.org:8080/#/c/12280/1/be/src/util/ubsan.h@83 PS1, Line 83: // The second block is worse because y is masquerading as a legitimate pointer to an A I guess this kind-of answers my question. -- To view, visit http://gerrit.cloudera.org:8080/12280 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: Iecdf301065da8f091a274e7a0585a11fcc79da7d Gerrit-Change-Number: 12280 Gerrit-PatchSet: 1 Gerrit-Owner: Jim Apple <jbapple-imp...@apache.org> Gerrit-Reviewer: Impala Public Jenkins <impala-public-jenk...@cloudera.com> Gerrit-Reviewer: Tim Armstrong <tarmstr...@cloudera.com> Gerrit-Comment-Date: Mon, 28 Jan 2019 10:43:06 +0000 Gerrit-HasComments: Yes