From 7df0d3b7fc581ee63102a70baa19d3919a28a624 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Mon, 6 Aug 2018 11:48:25 +0200 Subject: event/SignalMonitor: make SignalMonitorFinish() noexcept --- src/event/SignalMonitor.cxx | 4 ++-- src/event/SignalMonitor.hxx | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'src/event') diff --git a/src/event/SignalMonitor.cxx b/src/event/SignalMonitor.cxx index 71f603904..5c34d2057 100644 --- a/src/event/SignalMonitor.cxx +++ b/src/event/SignalMonitor.cxx @@ -147,7 +147,7 @@ x_sigaction(int signum, const struct sigaction &act) #endif void -SignalMonitorFinish() +SignalMonitorFinish() noexcept { #ifdef USE_SIGNALFD std::fill_n(signal_handlers, MAX_SIGNAL, nullptr); @@ -159,7 +159,7 @@ SignalMonitorFinish() for (unsigned i = 0; i < MAX_SIGNAL; ++i) { if (signal_handlers[i]) { - x_sigaction(i, sa); + sigaction(i, &sa, nullptr); signal_handlers[i] = nullptr; } } diff --git a/src/event/SignalMonitor.hxx b/src/event/SignalMonitor.hxx index 1930b3bcb..734977ec1 100644 --- a/src/event/SignalMonitor.hxx +++ b/src/event/SignalMonitor.hxx @@ -42,7 +42,7 @@ SignalMonitorInit(EventLoop &loop); * Deinitialise the signal monitor subsystem. */ void -SignalMonitorFinish(); +SignalMonitorFinish() noexcept; /** * Register a handler for the specified signal. The handler will be -- cgit v1.2.3