Skip to main content

lift_bytes

Function lift_bytes 

Source
pub unsafe fn lift_bytes(ptr: *const u8, len: usize) -> Option<Vec<u8>>
Expand description

Copy a (ptr, len) parameter into an owned Vec<u8>.

Returns None when ptr is null but len isn’t 0.

§Safety

Same contract as lift_byte_slice, for the duration of the call.