diff options
| author | Garrett D'Amore <garrett@damore.org> | 2024-11-30 08:37:25 -0500 |
|---|---|---|
| committer | Garrett D'Amore <garrett@damore.org> | 2024-12-07 14:12:43 -0800 |
| commit | 4f940cec0a6a5bcccd3ff0f389b66c169991968c (patch) | |
| tree | 62a26763359b650e7f91c535349ae1adaa81e7d5 /src/core/aio.h | |
| parent | 9c0b9d6e4ef3909ce52b75267b38fd659447e888 (diff) | |
| download | nng-4f940cec0a6a5bcccd3ff0f389b66c169991968c.tar.gz nng-4f940cec0a6a5bcccd3ff0f389b66c169991968c.tar.bz2 nng-4f940cec0a6a5bcccd3ff0f389b66c169991968c.zip | |
aio: make sure aio is initialized before certain operations
Operations that might be performed during teardown, such as reaping,
waiting, closing, freeing, should only be done if the aio has properly
been initialized. This is important for certain simple cases where
inline aio objects are used, and initialization of an outer object can
fail before the enclosed aio is initialized.
Diffstat (limited to 'src/core/aio.h')
| -rw-r--r-- | src/core/aio.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/core/aio.h b/src/core/aio.h index f56d2f58..5f7ddb69 100644 --- a/src/core/aio.h +++ b/src/core/aio.h @@ -214,6 +214,7 @@ struct nng_aio { bool a_expire_ok; // Expire from sleep is ok bool a_expiring; // Expiration in progress bool a_use_expire; // Use expire instead of timeout + bool a_init; // Initialized this nni_task a_task; // Read/write operations. |
