diff options
| author | Garrett D'Amore <garrett@damore.org> | 2022-04-18 10:25:03 -0400 |
|---|---|---|
| committer | Garrett D'Amore <garrett@damore.org> | 2022-04-18 17:41:21 -0400 |
| commit | 722bf4621703ef238fa81018f8c3e68bcef91354 (patch) | |
| tree | 1389cd6082ecae9ab0db1239f48861ebefea3c4c /include | |
| parent | d9897897fcf9d1276190b5d20955c72fd632acac (diff) | |
| download | nng-722bf4621703ef238fa81018f8c3e68bcef91354.tar.gz nng-722bf4621703ef238fa81018f8c3e68bcef91354.tar.bz2 nng-722bf4621703ef238fa81018f8c3e68bcef91354.zip | |
fixes #1574 Non-blocking version of nng_aio_wait / nng_aio_result
This introduces a new API, nng_aio_busy(), that can be used
to query the status of the aio without blocking.
Some minor documentation fixes are included.
Diffstat (limited to 'include')
| -rw-r--r-- | include/nng/nng.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/include/nng/nng.h b/include/nng/nng.h index 9aa9ed9a..811cb456 100644 --- a/include/nng/nng.h +++ b/include/nng/nng.h @@ -544,6 +544,12 @@ NNG_DECL void nng_aio_abort(nng_aio *, int); // callback or deadlock may occur. NNG_DECL void nng_aio_wait(nng_aio *); +// nng_aio_busy returns true if the aio is still busy processing the +// operation, or executing associated completion functions. Note that +// if the completion function schedules a new operation using the aio, +// then this function will continue to return true. +NNG_DECL bool nng_aio_busy(nng_aio *); + // nng_aio_set_msg sets the message structure to use for asynchronous // message send operations. NNG_DECL void nng_aio_set_msg(nng_aio *, nng_msg *); |
