diff options
| author | Garrett D'Amore <garrett@damore.org> | 2024-12-17 22:56:41 -0800 |
|---|---|---|
| committer | Garrett D'Amore <garrett@damore.org> | 2024-12-17 22:56:41 -0800 |
| commit | 6c949de1cb46182303a85864bad753c12142fa97 (patch) | |
| tree | 9b66786e0a22d4d38089d8c269d6e096ef0a8617 /src/platform/posix/posix_tcpconn.c | |
| parent | d83f5aea789f896c90208567a9e56599a439e90a (diff) | |
| download | nng-6c949de1cb46182303a85864bad753c12142fa97.tar.gz nng-6c949de1cb46182303a85864bad753c12142fa97.tar.bz2 nng-6c949de1cb46182303a85864bad753c12142fa97.zip | |
POSIX poller: add support for select, and for choosing the poller
Some platforms or configurations may not have more modern options
like kqueue or epoll, or may be constrained by policy.
Diffstat (limited to 'src/platform/posix/posix_tcpconn.c')
| -rw-r--r-- | src/platform/posix/posix_tcpconn.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/platform/posix/posix_tcpconn.c b/src/platform/posix/posix_tcpconn.c index ce5243b0..d49fc838 100644 --- a/src/platform/posix/posix_tcpconn.c +++ b/src/platform/posix/posix_tcpconn.c @@ -310,7 +310,7 @@ tcp_send(void *arg, nni_aio *aio) // means we didn't finish the job, so arm the poller to // complete us. if (nni_list_first(&c->writeq) == aio) { - nni_posix_pfd_arm(c->pfd, POLLOUT); + nni_posix_pfd_arm(c->pfd, NNI_POLL_OUT); } } nni_mtx_unlock(&c->mtx); @@ -344,7 +344,7 @@ tcp_recv(void *arg, nni_aio *aio) // means we didn't finish the job, so arm the poller to // complete us. if (nni_list_first(&c->readq) == aio) { - nni_posix_pfd_arm(c->pfd, POLLIN); + nni_posix_pfd_arm(c->pfd, NNI_POLL_IN); } } nni_mtx_unlock(&c->mtx); |
