NNG_AIO_WAIT(3)

πŸ“¦
version 1.12.0 Β· 4 versions
, in ubuntu stonking

πŸ’– 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 πŸ‘‘

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