mirror of
https://github.com/nzp-team/fteqw.git
synced 2024-11-26 13:50:53 +00:00
Added an option to prevent restarting. Users might object to always having it reset. Plus, if a user can get a crash, we can allow windows to let us know where abouts.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@425 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
parent
0f7ea1c673
commit
dd533981a0
1 changed files with 10 additions and 9 deletions
|
@ -641,7 +641,7 @@ void WINAPI StartQuakeServerService (DWORD argc, LPTSTR *argv)
|
|||
{
|
||||
printf(" [MY_SERVICE] RegisterServiceCtrlHandler failed %d\n", GetLastError());
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
RegOpenKey(HKEY_LOCAL_MACHINE, "SOFTWARE\\FTE", &hk);
|
||||
|
@ -703,14 +703,6 @@ SERVICE_TABLE_ENTRY DispatchTable[] =
|
|||
qboolean NET_Sleep(int msec, qboolean stdinissocket);
|
||||
int main (int argc, char **argv)
|
||||
{
|
||||
#ifndef _DEBUG
|
||||
{
|
||||
signal (SIGFPE, Signal_Error_Handler);
|
||||
signal (SIGILL, Signal_Error_Handler);
|
||||
signal (SIGSEGV, Signal_Error_Handler);
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef USESERVICE
|
||||
if (StartServiceCtrlDispatcher( DispatchTable))
|
||||
{
|
||||
|
@ -731,6 +723,15 @@ int main (int argc, char **argv)
|
|||
return true;
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifndef _DEBUG
|
||||
if (COM_CheckParm("-noreset"))
|
||||
{
|
||||
signal (SIGFPE, Signal_Error_Handler);
|
||||
signal (SIGILL, Signal_Error_Handler);
|
||||
signal (SIGSEGV, Signal_Error_Handler);
|
||||
}
|
||||
#endif
|
||||
StartQuakeServer();
|
||||
|
||||
ServerMainLoop();
|
||||
|
|
Loading…
Reference in a new issue