Skip to content

Commit

Permalink
Fix a memcheck error in ORC writer (#9896)
Browse files Browse the repository at this point in the history
Follow up of #9808
Skips some kernels when input columns are empty to avoid OOB memory access.

Authors:
  - Vukasin Milovanovic (https://github.com/vuule)

Approvers:
  - Devavret Makkar (https://github.com/devavret)
  - Nghia Truong (https://github.com/ttnghia)
  - David Wendt (https://github.com/davidwendt)

URL: #9896
  • Loading branch information
vuule authored Dec 14, 2021
1 parent 7a23f1a commit 61794aa
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions cpp/src/io/orc/writer_impl.cu
Original file line number Diff line number Diff line change
Expand Up @@ -1018,6 +1018,7 @@ std::vector<StripeInformation> writer::impl::gather_stripes(
hostdevice_2dvector<gpu::encoder_chunk_streams>* enc_streams,
hostdevice_2dvector<gpu::StripeStream>* strm_desc)
{
if (segmentation.num_stripes() == 0) { return {}; }
std::vector<StripeInformation> stripes(segmentation.num_stripes());
for (auto const& stripe : segmentation.stripes) {
for (size_t col_idx = 0; col_idx < enc_streams->size().first; col_idx++) {
Expand Down

0 comments on commit 61794aa

Please sign in to comment.