mirror of
https://github.com/napi-rs/napi-rs.git
synced 2025-12-08 19:56:07 +00:00
In Rust 1.78, when debug assertions are enabled, slice::from_raw_parts panics if the provided data is a null pointer. This is possible through JsArrayBufferValue::new() as well as through JsArrayBuffer::into_value, when napi_get_arraybuffer_info returns a null pointer due to a zero length buffer.