Skip to main content

user_copy

Function user_copy 

Source
pub unsafe extern "C" fn user_copy(
    dst: *mut u8,
    src: *const u8,
    size: usize,
) -> usize
Available on crate feature uspace only.
Expand description

Copies data from source to destination, where addresses may be in user space. Equivalent to memcpy.

§Safety

This function is unsafe because it performs raw memory operations.

§Returns

Returns the number of bytes not copied. This means 0 indicates success, while a value > 0 indicates failure.