Function pact_matching_ffi::log::fetch_log_buffer[][src]

#[no_mangle]
pub unsafe extern "C" fn fetch_log_buffer(
    log_id: *const c_char
) -> *const c_char
Expand description

Fetch the in-memory logger buffer contents. This will only have any contents if the buffer sink has been configured to log to. The contents will be allocated on the heap and will need to be freed with string_delete.

Fetches the logs associated with the provided identifier, or uses the “global” one if the identifier is not specified (i.e. NULL).

Returns a NULL pointer if the buffer can’t be fetched. This can occur is there is not sufficient memory to make a copy of the contents or the buffer contains non-UTF-8 characters.