#include <signal.h>
#include "../game/q_shared.h"
#include "../qcommon/qcommon.h"
#include "../renderer/tr_local.h"
Include dependency graph for linux_signals.c:

Go to the source code of this file.
Functions | |
| void | InitSig (void) |
| void | signal_handler (int sig) |
| void | Sys_Exit (int) |
Variables | |
| qboolean | signalcaught = qfalse |
|
|
Definition at line 50 of file linux_signals.c. References SIGFPE, SIGILL, signal, signal_handler(), SIGSEGV, and SIGTERM. Referenced by GLimp_Init(), and main(). 00051 {
00052 signal(SIGHUP, signal_handler);
00053 signal(SIGQUIT, signal_handler);
00054 signal(SIGILL, signal_handler);
00055 signal(SIGTRAP, signal_handler);
00056 signal(SIGIOT, signal_handler);
00057 signal(SIGBUS, signal_handler);
00058 signal(SIGFPE, signal_handler);
00059 signal(SIGSEGV, signal_handler);
00060 signal(SIGTERM, signal_handler);
00061 }
|
Here is the call graph for this function:

|
|
Definition at line 34 of file linux_signals.c. References GLimp_Shutdown(), printf(), signalcaught, and Sys_Exit(). Referenced by InitSig(). 00035 {
00036 if (signalcaught)
00037 {
00038 printf("DOUBLE SIGNAL FAULT: Received signal %d, exiting...\n", sig);
00039 Sys_Exit(1); // bk010104 - abstraction
00040 }
00041
00042 signalcaught = qtrue;
00043 printf("Received signal %d, exiting...\n", sig);
00044 #ifndef DEDICATED
00045 GLimp_Shutdown(); // bk010104 - shouldn't this be CL_Shutdown
00046 #endif
00047 Sys_Exit(0); // bk010104 - abstraction NOTE TTimo send a 0 to avoid DOUBLE SIGNAL FAULT
00048 }
|
Here is the call graph for this function:

|
|
Definition at line 321 of file unix_main.c. References assert, exit(), and Sys_ConsoleInputShutdown(). Referenced by signal_handler(), Sys_Error(), Sys_ParseArgs(), and Sys_Quit(). 00321 {
00322 Sys_ConsoleInputShutdown();
00323
00324 #ifdef NDEBUG // regular behavior
00325
00326 // We can't do this
00327 // as long as GL DLL's keep installing with atexit...
00328 //exit(ex);
00329 _exit(ex);
00330 #else
00331
00332 // Give me a backtrace on error exits.
00333 assert( ex == 0 );
00334 exit(ex);
00335 #endif
00336 }
|
Here is the call graph for this function:

|
|
Definition at line 30 of file linux_signals.c. Referenced by signal_handler(). |
1.3.9.1