Strip dead Windows-only code paths, add LTO/march build flags, seed default GM account
Removes now-unreachable #ifdef _WIN32 branches across Common/ and the three server binaries (all builds are Linux-only), deletes the entirely unused SEH exception-handling shim and an orphaned vendored MySQL client header. Enables LTO and -march=x86-64-v2 in Release builds for a small free perf win. Also seeds a default GM account (gmadmin/changeme) via database sql files/gm_account.sql so a fresh deploy has something to log into the web admin panel with, switches the MariaDB data directory from a Docker named volume to a host bind mount for visibility/backup, and expands the README with a fuller Docker deployment walkthrough. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
1 parent
1e47731d7a
commit
1998bf4273
27 files changed
+101
-1178
No files matched your search
@@ -38,9 +38,6 @@ void StartSignal( )
|
||||
signal( SIGFPE, HandleSignal );
|
||||
signal( SIGSEGV, HandleSignal );
|
||||
signal( SIGTERM, HandleSignal );
|
||||
#ifdef _WIN32
|
||||
signal( SIGBREAK, HandleSignal );
|
||||
#endif
|
||||
signal( SIGABRT, HandleSignal );
|
||||
}
|
||||
|
||||
@@ -51,9 +48,6 @@ void StopSignal( )
|
||||
signal( SIGFPE, 0 );
|
||||
signal( SIGSEGV, 0 );
|
||||
signal( SIGTERM, 0 );
|
||||
#ifdef _WIN32
|
||||
signal( SIGBREAK, 0 );
|
||||
#endif
|
||||
signal( SIGABRT, 0 );
|
||||
}
|
||||
|
||||
@@ -63,22 +57,14 @@ void HandleSignal( int num )
|
||||
{
|
||||
case SIGINT:/* Interactive attention */
|
||||
Log( MSG_ERROR, "Signal received: SIGINT" );
|
||||
#ifdef _WIN32
|
||||
Sleep(1000);
|
||||
#else
|
||||
usleep(1000);
|
||||
#endif
|
||||
delete GServer;
|
||||
raise(num);
|
||||
break;
|
||||
case SIGILL:/* Illegal instruction */
|
||||
Log( MSG_ERROR, "Signal received: SIGILL, Server will be closed, Trying to save..." );
|
||||
GServer->DisconnectAll();
|
||||
#ifdef _WIN32
|
||||
Sleep(1000);
|
||||
#else
|
||||
usleep(1000);
|
||||
#endif
|
||||
delete GServer;
|
||||
raise(num);
|
||||
break;
|
||||
@@ -91,25 +77,15 @@ void HandleSignal( int num )
|
||||
case SIGSEGV:/* Segmentation violation */
|
||||
Log( MSG_ERROR, "Signal received: SIGSEGV, Server will be closed, Trying to save..." );
|
||||
GServer->DisconnectAll();
|
||||
#ifdef _WIN32
|
||||
Sleep(1000);
|
||||
#else
|
||||
usleep(1000);
|
||||
#endif
|
||||
delete GServer;
|
||||
raise(num);
|
||||
break;
|
||||
|
||||
raise(num);
|
||||
break;
|
||||
|
||||
case SIGTERM:/* Termination request */
|
||||
Log( MSG_INFO, "Signal received: SIGTERM, Server will be closed" );
|
||||
pthread_create( &GServer->WorldThread[SHUTDOWN_THREAD], NULL, (void *(__cdecl *)(void *))ShutdownServer, (PVOID)0);
|
||||
break;
|
||||
#ifdef _WIN32
|
||||
case SIGBREAK:/* Control-break */
|
||||
Log( MSG_INFO, "Signal received: SIGBREAK, Server will be closed" );
|
||||
pthread_create( &GServer->WorldThread[SHUTDOWN_THREAD], NULL, (void *(__cdecl *)(void *))ShutdownServer, (PVOID)0);
|
||||
break;
|
||||
#endif
|
||||
default:
|
||||
cout << "Unknown Signal Number: " << num << endl;
|
||||
raise(num);
|
||||
|
||||
Reference in new issue
Block a user