diff options
Diffstat (limited to 'test/socket_test.cpp')
-rw-r--r-- | test/socket_test.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/test/socket_test.cpp b/test/socket_test.cpp index b29788c..1f2d736 100644 --- a/test/socket_test.cpp +++ b/test/socket_test.cpp @@ -60,11 +60,15 @@ main() if (pfds[0].revents & POLLIN) { const std::shared_ptr<Socket> conn = unix_server_sock.accept(); + assert(conn); + assert(conn->fd()); ++n_received; } if (pfds[1].revents & POLLIN) { const std::shared_ptr<Socket> conn = tcp_server_sock.accept(); + assert(conn); + assert(conn->fd()); ++n_received; } } @@ -72,7 +76,6 @@ main() unix_server_sock.shutdown(); tcp_server_sock.shutdown(); unlink("/tmp/raul_test_sock"); - fprintf(stderr, "n received: %u\n", n_received); return n_received != 2; } |