Function gnunet_sys::GNUNET_DISK_file_read_non_blocking[][src]

pub unsafe extern "C" fn GNUNET_DISK_file_read_non_blocking(
    h: *const GNUNET_DISK_FileHandle,
    result: *mut c_void,
    len: usize
) -> isize

Read the contents of a binary file into a buffer. Guarantees not to block (returns GNUNET_SYSERR and sets errno to EAGAIN when no data can be read).

@param h handle to an open file @param result the buffer to write the result to @param len the maximum number of bytes to read @return the number of bytes read on success, #GNUNET_SYSERR on failure