GH721: Duplicated flags in doc
[openssl.git] / doc / ssl / SSL_get_async_wait_fd.pod
1 =pod
2
3 =head1 NAME
4
5 SSL_waiting_for_async, SSL_get_async_wait_fd - manage asynchronous operations
6
7 =head1 SYNOPSIS
8
9  #include <openssl/ssl.h>
10
11  int SSL_waiting_for_async(SSL *s);
12  int SSL_get_async_wait_fd(SSL *s);
13
14 =head1 DESCRIPTION
15
16 SSL_waiting_for_async() determines whether an SSL connection is currently
17 waiting for asynchronous operations to complete (see the SSL_MODE_ASYNC mode in
18 L<SSL_CTX_set_mode(3)>).
19
20 SSL_get_async_wait_fd() returns a file descriptor which can be used in a call to
21 select() or poll() to determine whether the current asynchronous operation has
22 completed or not. A completed operation will result in data appearing as
23 "read ready" on the file descriptor (no actual data should be read from the
24 file descriptor). This function should only be called if the SSL object is
25 currently waiting for asynchronous work to complete (i.e. SSL_ERROR_WANT_ASYNC
26 has been received - see L<SSL_get_error(3)>).
27
28 =head1 RETURN VALUES
29
30 SSL_waiting_for_async() will return 1 if the current SSL operation is waiting
31 for an async operation to complete and 0 otherwise.
32
33 SSL_get_async_wait_fd() will return a file descriptor that can be used in a call
34 to select() or poll() to wait for asynchronous work to complete, or -1 on error.
35
36 =head1 SEE ALSO
37
38 L<SSL_get_error(3)>, L<SSL_CTX_set_mode(3)>
39
40 =head1 HISTORY
41
42 SSL_waiting_for_async() and SSL_get_async_wait_fd() were first added to
43 OpenSSL 1.1.0
44
45 =cut