From: Joel Rosdahl Date: Thu, 9 Sep 2021 18:55:53 +0000 (+0200) Subject: fix(redis-storage): Ignore SIGPIPE X-Git-Tag: v4.4.1~3 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=b2a88e7;p=thirdparty%2Fccache.git fix(redis-storage): Ignore SIGPIPE libhiredis doesn’t pass MSG_NOSIGNAL to send to ccache can die from SIGPIPE. Disable SIGPIPE so that the socket code receives EPIPE correctly. This should also fix a similar problem with the HTTP storage backend. Fixes #931. --- diff --git a/src/SignalHandler.cpp b/src/SignalHandler.cpp index 9051eeb0d..2d32ac6d0 100644 --- a/src/SignalHandler.cpp +++ b/src/SignalHandler.cpp @@ -71,6 +71,8 @@ SignalHandler::SignalHandler(Context& ctx) : m_ctx(ctx) # ifdef SIGQUIT register_signal_handler(SIGQUIT); # endif + + signal(SIGPIPE, SIG_IGN); // NOLINT: This is no error, clang-tidy } SignalHandler::~SignalHandler()