alamb commented on code in PR #8901:
URL: https://github.com/apache/arrow-rs/pull/8901#discussion_r2550245086
##########
arrow-array/src/array/fixed_size_binary_array.rs:
##########
@@ -119,10 +119,10 @@ impl FixedSizeBinaryArray {
/// * `size < 0`
/// * `size * len` would overflow `usize`
pub fn new_null(size: i32, len: usize) -> Self {
- let capacity = size.to_usize().unwrap().checked_mul(len).unwrap();
+ let capacity_in_bytes =
size.to_usize().unwrap().checked_mul(len).unwrap();
Self {
data_type: DataType::FixedSizeBinary(size),
- value_data: MutableBuffer::new(capacity).into(),
+ value_data: MutableBuffer::new_null(capacity_in_bytes * 8).into(),
Review Comment:
Where does the `8` come from?
--
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]