Closed bamarsha closed 1 year ago
bytes is a slice into a memory buffer that is scoped to the block in let bytes = unsafe { ... };. When PyBytes::new copies it, the memory buffer has already been freed.
bytes
let bytes = unsafe { ... };
PyBytes::new
bytes
is a slice into a memory buffer that is scoped to the block inlet bytes = unsafe { ... };
. WhenPyBytes::new
copies it, the memory buffer has already been freed.