reduce SignalHandler dependency on StepMania.cpp

This commit is contained in:
Glenn Maynard
2004-03-12 01:09:38 +00:00
parent 14f6a6f510
commit 6ba7f1d2e6
3 changed files with 48 additions and 17 deletions
@@ -3,7 +3,6 @@
#include "RageLog.h"
#include "SignalHandler.h"
#include "GetSysInfo.h"
#include "StepMania.h"
#include <unistd.h>
#include <sys/mman.h>
@@ -49,18 +48,8 @@ SaveSignals::~SaveSignals()
static void SigHandler(int sig)
{
if( sig == SIGINT || sig == SIGQUIT )
{
/* ^C. */
ExitGame();
return;
}
for(unsigned i = 0; i < handlers.size(); ++i)
handlers[i](sig);
kill( 0, SIGKILL );
// _exit(1);
}
/* Hook up events to fatal signals, so we can clean up if we're killed. */