diff options
author | Brian Paul <[email protected]> | 2000-02-12 01:36:40 +0000 |
---|---|---|
committer | Brian Paul <[email protected]> | 2000-02-12 01:36:40 +0000 |
commit | bd986282f388e367fa22a232d44987e35fd06b37 (patch) | |
tree | df5a3e95de2e5ad88938d424a1576f4984e8c67f /src | |
parent | 15b40dfe75b72dd4e5c38bb8dc6d7e68e5a353a5 (diff) |
added MESA_FX_NO_SIGNALS env var (Michael Vance)
Diffstat (limited to 'src')
-rw-r--r-- | src/mesa/drivers/glide/fxapi.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/mesa/drivers/glide/fxapi.c b/src/mesa/drivers/glide/fxapi.c index ba996cabf4c..0b96cf4399a 100644 --- a/src/mesa/drivers/glide/fxapi.c +++ b/src/mesa/drivers/glide/fxapi.c @@ -1057,7 +1057,8 @@ fxMesaContext GLAPIENTRY fxMesaCreateContext(GLuint win, /* install signal handlers */ #if defined(__linux__) - if (fxMesa->glCtx->CatchSignals) { + /* Only install if environment var. is not set. */ + if (fxMesa->glCtx->CatchSignals && !getenv("MESA_FX_NO_SIGNALS")) { signal(SIGINT,cleangraphics_handler); signal(SIGHUP,cleangraphics_handler); signal(SIGPIPE,cleangraphics_handler); @@ -1300,7 +1301,10 @@ int GLAPIENTRY fxQueryHardware(void) #if defined(__WIN32__) onexit((_onexit_t)cleangraphics); #elif defined(__linux__) - atexit(cleangraphics); + /* Only register handler if environment variable is not defined. */ + if (!getenv("MESA_FX_NO_SIGNALS")) { + atexit(cleangraphics); + } #endif } |