nng_sleep_aio(3)

nng_sleep_aio3

Sleep asynchronously

Usage

#include <nng/nng.h>
void nng_sleep_aio(nng_duration msec, nng_aio *aio);

Overview

The nng_sleep_aio() function provides an asynchronous delay mechanism, causing the callback for aio to be executed after msec milliseconds. If the sleep finishes completely, the result will always be zero.

Note

If a timeout is set on aio using nng_aio_set_timeout(), and it is shorter than msec, then the sleep will wake up early, with a result code of NNG_ETIMEDOUT.

Return values

None.

Errors

None.

From libnng-dev 1.10.1-2 in Debian 13 (Trixie). Parsed by carta from the page's man source.