aboutgitcodebugslistschat
path: root/tap.c
diff options
context:
space:
mode:
Diffstat (limited to 'tap.c')
-rw-r--r--tap.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/tap.c b/tap.c
index e0d3ee5..b318327 100644
--- a/tap.c
+++ b/tap.c
@@ -1493,6 +1493,10 @@ void tap_listen_handler(struct ctx *c, uint32_t events)
}
c->fd_tap = accept4(c->fd_tap_listen, NULL, NULL, SOCK_CLOEXEC);
+ if (c->fd_tap < 0) {
+ warn_perror("Error accepting tap client");
+ return;
+ }
if (!getsockopt(c->fd_tap, SOL_SOCKET, SO_PEERCRED, &ucred, &len))
info("accepted connection from PID %i", ucred.pid);