#[no_mangle]
pub unsafe extern "C" fn crosvm_client_net_tap_detach(
    socket_path: *const c_char,
    bus_num: u8
) -> bool
Expand description

Detaches a hotplugged tap device from the crosvm instance with control socket at socket_path.

§Arguments

  • socket_path - Path to the crosvm control socket
  • bus_num - Bus number of the tap device to be removed.

The function returns true on success, and false on failure.

§Safety

Function is unsafe due to raw pointer usage - socket_path is assumed to point to a null-terminated Cstr. Function checks that the pointers are not null, but caller need to check the validity of the pointer.