Associate a waitable file descriptor with a key in the wait context.

Synopsis

Declared in <openssl/async.h>

int
ASYNC_WAIT_CTX_set_wait_fd(
    ASYNC_WAIT_CTX* ctx,
    void const* key,
    int fd,
    void* custom_data,
    void(* cleanup)(ASYNC_WAIT_CTX*, void const*, int, void*));

Return Value

1 on success, or 0 on error.

Parameters

Name

Description

ctx

Wait context to update.

key

Unique key identifying this wait fd.

fd

File descriptor to wait on.

custom_data

Optional application data for the cleanup callback.

cleanup

Optional callback to release custom_data when the fd is cleared.

Created with MrDocs