NNG_AIO_WAIT(3)
π nng_aio_wait β wait for asynchronous I/O operation π
okay bestie, welcome to the NNG Reference Manual entry for nng_aio_wait(3) πβ¨ this one's short and sweet, we love a low-effort bop, let's get into it π«Ά
β¨ NAME β¨
nng_aio_wait β wait for asynchronous I/O operation πΈ
it's literally in the name, she waits. no cap. π
π SYNOPSIS π
#include <nng/nng.h>
void nng_aio_wait(nng_aio *aio);
that's the whole thing π include the header, call the function, that's it. iconic behaviour honestly.
π¦ DESCRIPTION π¦
so the nng_aio_wait() function waits for an asynchronous I/O operation to complete. she's just standing there. patiently. like a bestie holding your iced coffee while you tie your shoe βπ
and here's the cute part: if the operation has not been started, or has already completed, then it returns immediately πβοΈπ¨ no waiting, no drama, she just says "oh we're done? okay bye."
also, if a callback was set with aio when it was allocated, then this function will not be called until the callback has completed. so like, she's polite, she queues up behind the callback πβ¨
β οΈ Important β οΈ bestie listen to me, this is the serious part, okay? This function should never be called from a function that itself is a callback of an aio, either this one or any other. Doing so may result in a deadlock ππ and not the cute kind of stuck, the actual program-is-frozen-forever kind. please don't. i'm begging. π
π RETURN VALUES π
None. π«₯
literally nothing, she returns void, there is no value to look at, go home, nothing to see here π
π ERRORS π
None. β¨
no errors, no surprises, no plot twists, she's just that reliable π§ββοΈ
π SEE ALSO π
nng_aio_abort(3)nng_aio_alloc(3)nng_aio_busy(3)nng_aio(5)nng(7)
go read those too, staying informed is main character energy ππ
and that's the whole vibe β¨ this one's from the NNG Reference Manual, dated 2026-06-30 πΈ so when you cite it in your lil code review, you know it's fresh. mwah, love u, go write some async code bestie π«Άππ¦
π¦ where this page comes from
- ubuntu stonking: libnng-dev 1.12.0-1 Β· MIT OR Apache-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms