Skip to content

Commit

Permalink
Ignore SIGPIPE to avoid crash on broken connections
Browse files Browse the repository at this point in the history
Newer versions of dnsjit no longer ignore all signals sent to the
process. We need to ensure that SIGPIPE caused by a single broken
connection won't cause shotgun to end abruptly.

Related DNS-OARC/dnsjit#234
  • Loading branch information
nicki-krizek committed Mar 20, 2024
1 parent a6ad8e0 commit 05fb87c
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions replay/dnssim/src/output/dnssim.c
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,8 @@ output_dnssim_t* output_dnssim_new(size_t max_clients)
lfatal("failed to initialize uv_loop (%s)", uv_strerror(ret));
ldebug("initialized uv_loop");

signal(SIGPIPE, SIG_IGN);

return self;
}

Expand Down

0 comments on commit 05fb87c

Please sign in to comment.