summaryrefslogtreecommitdiffstats
path: root/tools/monitor/main.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tools/monitor/main.cpp')
-rw-r--r--tools/monitor/main.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/tools/monitor/main.cpp b/tools/monitor/main.cpp
index 0d8f88a..a3c7ae7 100644
--- a/tools/monitor/main.cpp
+++ b/tools/monitor/main.cpp
@@ -11,6 +11,7 @@
#include <signal.h>
#include <sys/socket.h>
+#include <unistd.h>
/**
* A thread that keeps a server running. It restarts the server when it quits
@@ -245,14 +246,16 @@ void ServerMonitor::setupUnixSignalHandlers()
void ServerMonitor::termSignalHandler(int)
{
char tmp = 1;
- ::write(sigtermFd[0], &tmp, sizeof(tmp));
+ ssize_t num = ::write(sigtermFd[0], &tmp, sizeof(tmp));
+ Q_UNUSED(num);
}
void ServerMonitor::handleSigTerm()
{
snTerm->setEnabled(false);
char tmp;
- ::read(sigtermFd[1], &tmp, sizeof(tmp));
+ ssize_t num = ::read(sigtermFd[1], &tmp, sizeof(tmp));
+ Q_UNUSED(num);
QCoreApplication::quit();
@@ -278,8 +281,6 @@ int main(int argc, char *argv[])
<< "src/manaserv-game";
}
- app.arguments();
-
ServerMonitor monitor(serverExecutables);
monitor.start();