Skip to main content

nix_get_string_callback

Type Alias nix_get_string_callback 

Source
pub type nix_get_string_callback = Option<unsafe extern "C" fn(start: *const c_char, n: c_uint, user_data: *mut c_void)>;
Expand description

Called to get the value of a string owned by Nix. The start data is borrowed and the function must not assume that the buffer persists after it returns.

§Arguments

  • start [in] - the string to copy.
  • n [in] - the string length.
  • user_data [in] - optional, arbitrary data, passed to the nix_get_string_callback when it’s called.

Aliased Type§

pub enum nix_get_string_callback {
    None,
    Some(unsafe extern "C" fn(*const i8, u32, *mut c_void)),
}

Variants§

§1.0.0

None

No value.

§1.0.0

Some(unsafe extern "C" fn(*const i8, u32, *mut c_void))

Some value of type T.