From b93d359332a958b1df83aa68ccdb6e6655313a60 Mon Sep 17 00:00:00 2001 From: Marten Richter Date: Sat, 25 Feb 2017 10:48:36 +0100 Subject: [PATCH] Fix new signal handlers for windows port --- command.cc | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/command.cc b/command.cc index 6c6d99c..0156f87 100644 --- a/command.cc +++ b/command.cc @@ -276,6 +276,7 @@ void Command::run() void Command::setSignal(int signalReceived) { +#ifndef WIN32 if (signalReceived == SIGINT) signals |= SIG_INT; else if (signalReceived == SIGTERM) @@ -286,10 +287,12 @@ void Command::setSignal(int signalReceived) signals |= SIG_USR2; else if (signalReceived == SIGURG) signals |= SIG_URG; +#endif } void Command::processSignals() { +#ifndef WIN32 if (signals & SIG_INT) { signals = signals & ~SIG_INT; @@ -321,6 +324,7 @@ void Command::processSignals() logger->log("Command", Log::NOTICE, "URG signal"); // This is used to break from getButtonPress to process the message queue signals = signals & ~SIG_URG; } +#endif } void Command::postMessage(Message* m) -- 2.39.5