Function crosvm_control::crosvm_client_swap_status
source · #[no_mangle]
pub unsafe extern "C" fn crosvm_client_swap_status(
socket_path: *const c_char,
status: *mut SwapStatus,
) -> bool
Expand description
Returns vmm-swap status of the crosvm instance whose control socket is listening on
socket_path
.
The parameters status
is optional and will only be written to if they are non-null.
The function returns true on success or false if an error occurred.
§Safety
Function is unsafe due to raw pointer usage - socket_path
should be a non-null pointer to a C
string that is valid for reads and not modified for the duration of the call, and that status
is a non-null pointer to a SwapStatus
valid for writes that is not externally modified for
the duration of the call.