summaryrefslogtreecommitdiff
path: root/main.c
diff options
context:
space:
mode:
authorDavid Härdeman <david@hardeman.nu>2020-06-05 22:04:01 +0200
committerDavid Härdeman <david@hardeman.nu>2020-06-05 22:04:01 +0200
commit8e301216143cb96d39a941a9c5fcb90319ef53c7 (patch)
tree066ea8b408ff49e20e2be2303364a35ff1731d15 /main.c
parenta683051b05930d1dd2766b98494bbd124817a6dd (diff)
Add enough functionality to actually be able to proxy a connection
Diffstat (limited to 'main.c')
-rw-r--r--main.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/main.c b/main.c
index f9df355..2385bf8 100644
--- a/main.c
+++ b/main.c
@@ -250,6 +250,9 @@ signalfd_init(struct cfg *cfg)
sigaction(SIGHUP, &action, NULL);
sigaction(SIGTERM, &action, NULL);
+ action.sa_handler = SIG_IGN;
+ sigaction(SIGPIPE, &action, NULL);
+
sfd = eventfd(0, EFD_CLOEXEC);
if (sfd < 0)
perrordie("eventfd");