Function s2n_quic::provider::tls::default::ffi::s2n_connection_set_recv_ctx

source ·
pub unsafe extern "C" fn s2n_connection_set_recv_ctx(
    conn: *mut s2n_connection,
    ctx: *mut c_void
) -> i32
Expand description

Set a context containing anything needed in the recv callback function (for example, a file descriptor), the buffer holding data to be sent or received, and the length of the buffer.

@note The io_context passed to the callbacks may be set separately using s2n_connection_set_recv_ctx and s2n_connection_set_send_ctx.

@param conn The connection object being updated @param ctx A user provided context that the callback will be invoked with @returns S2N_SUCCESS on success. S2N_FAILURE on failure