emkornfield commented on a change in pull request #11907:
URL: https://github.com/apache/arrow/pull/11907#discussion_r765109722



##########
File path: cpp/src/arrow/util/bit_stream_utils.h
##########
@@ -324,11 +324,12 @@ inline int BitReader::GetBatch(int num_bits, T* v, int 
batch_size) {
   int max_bytes = max_bytes_;
   const uint8_t* buffer = buffer_;
 
-  uint64_t needed_bits = num_bits * batch_size;
+  const int64_t needed_bits = num_bits * static_cast<int64_t>(batch_size);

Review comment:
       not clear from the context but do we need to worry about overflow as 
well?




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to