Skip to content

Commit

Permalink
Fix miri error in try_from_trusted_len_iter (#1497)
Browse files Browse the repository at this point in the history
  • Loading branch information
jhorstmann authored Mar 29, 2022
1 parent f1eba3c commit 4022c11
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion arrow/src/buffer/mutable.rs
Original file line number Diff line number Diff line change
Expand Up @@ -538,8 +538,9 @@ impl MutableBuffer {

let mut dst = buffer.data.as_ptr();
for item in iterator {
let item = item?;
// note how there is no reserve here (compared with `extend_from_iter`)
let src = item?.to_byte_slice().as_ptr();
let src = item.to_byte_slice().as_ptr();
std::ptr::copy_nonoverlapping(src, dst, item_size);
dst = dst.add(item_size);
}
Expand Down

0 comments on commit 4022c11

Please sign in to comment.