Function librbd_sys::rbd_list_lockers
[−]
[src]
pub unsafe extern "C" fn rbd_list_lockers(
image: rbd_image_t,
exclusive: *mut c_int,
tag: *mut c_char,
tag_len: *mut size_t,
clients: *mut c_char,
clients_len: *mut size_t,
cookies: *mut c_char,
cookies_len: *mut size_t,
addrs: *mut c_char,
addrs_len: *mut size_t
) -> ssize_t
List clients that have locked the image and information about the lock.
The number of bytes required in each buffer is put in the corresponding size out parameter. If any of the provided buffers are too short, -ERANGE is returned after these sizes are filled in.
Arguments
image
which image (and implicitly snapshot) to list lockers ofexclusive
where to store whether the lock is exclusive (1) or shared (0)tag
where to store the tag associated with the imagetag_len
number of bytes in tag bufferclients
buffer in which locker clients are stored, separated by '\0'clients_len
number of bytes in the clients buffercookies
buffer in which locker cookies are stored, separated by '\0'cookies_len
number of bytes in the cookies bufferaddrs
buffer in which locker addresses are stored, separated by '\0'addrs_len
number of bytes in the clients buffer @returns number of lockers on success, negative error code on failure @returns -ERANGE if any of the buffers are too short