diff options
| author | Garrett D'Amore <garrett@damore.org> | 2024-11-02 13:57:53 -0700 |
|---|---|---|
| committer | Garrett D'Amore <garrett@damore.org> | 2024-11-02 14:47:50 -0700 |
| commit | 279180c1d07fc2c4c0bfa8f5a418cb02c4b87863 (patch) | |
| tree | b451ac7f845062674d6ab45eb5d530628d3ff47c /src/core/sock_test.c | |
| parent | 9b27984d0e2da430b78a975e59f55c96de5f6056 (diff) | |
| download | nng-279180c1d07fc2c4c0bfa8f5a418cb02c4b87863.tar.gz nng-279180c1d07fc2c4c0bfa8f5a418cb02c4b87863.tar.bz2 nng-279180c1d07fc2c4c0bfa8f5a418cb02c4b87863.zip | |
NNG_OPT_RECVFD and NNG_OPT_SENDFD converted to functions.
These options are removed entirely, and their functionality is now
available via special functions, `nng_socket_get_send_poll_fd` and
`nng_socket_get_recv_poll_fd`, making these first class methods on
the socket.
This eliminates a bit of wasteful code, and provides type safety
for these methods.
Diffstat (limited to 'src/core/sock_test.c')
| -rw-r--r-- | src/core/sock_test.c | 11 |
1 files changed, 0 insertions, 11 deletions
diff --git a/src/core/sock_test.c b/src/core/sock_test.c index f785d9c0..7641ea1f 100644 --- a/src/core/sock_test.c +++ b/src/core/sock_test.c @@ -79,16 +79,6 @@ test_send_nonblock(void) } void -test_readonly_options(void) -{ - nng_socket s1; - NUTS_OPEN(s1); - NUTS_FAIL(nng_socket_set_int(s1, NNG_OPT_RECVFD, 0), NNG_EREADONLY); - NUTS_FAIL(nng_socket_set_int(s1, NNG_OPT_SENDFD, 0), NNG_EREADONLY); - NUTS_CLOSE(s1); -} - -void test_socket_base(void) { nng_socket s1 = NNG_SOCKET_INITIALIZER; @@ -596,7 +586,6 @@ NUTS_TESTS = { { "recv non-block", test_recv_nonblock }, { "send timeout", test_send_timeout }, { "send non-block", test_send_nonblock }, - { "read only options", test_readonly_options }, { "socket base", test_socket_base }, { "socket name", test_socket_name }, { "socket name oversize", test_socket_name_oversize }, |
