summaryrefslogtreecommitdiff
path: root/src/client/cl_cgame.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/client/cl_cgame.c')
-rw-r--r--src/client/cl_cgame.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/client/cl_cgame.c b/src/client/cl_cgame.c
index 40714a56..84b58d74 100644
--- a/src/client/cl_cgame.c
+++ b/src/client/cl_cgame.c
@@ -385,7 +385,7 @@ CL_ShutdonwCGame
====================
*/
void CL_ShutdownCGame( void ) {
- cls.keyCatchers &= ~KEYCATCH_CGAME;
+ Key_SetCatcher( Key_GetCatcher( ) & ~KEYCATCH_CGAME );
cls.cgameStarted = qfalse;
if ( !cgvm ) {
return;
@@ -619,7 +619,8 @@ intptr_t CL_CgameSystemCalls( intptr_t *args ) {
case CG_KEY_GETCATCHER:
return Key_GetCatcher();
case CG_KEY_SETCATCHER:
- Key_SetCatcher( args[1] );
+ // Don't allow the cgame module to close the console
+ Key_SetCatcher( args[1] | ( Key_GetCatcher( ) & KEYCATCH_CONSOLE ) );
return 0;
case CG_KEY_GETKEY:
return Key_GetKey( VMA(1) );