From 85058284a009de6f425843e29ce6529edcb80688 Mon Sep 17 00:00:00 2001 From: thilo Date: Tue, 29 Apr 2008 22:49:37 +0000 Subject: Make forced unloading work in more cases than just server disconnects git-svn-id: svn://svn.icculus.org/quake3/trunk@1333 edf5b092-35ff-0310-97b2-ce42778d08ea --- code/qcommon/common.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'code/qcommon') diff --git a/code/qcommon/common.c b/code/qcommon/common.c index d7b6cb2..7e695db 100644 --- a/code/qcommon/common.c +++ b/code/qcommon/common.c @@ -289,7 +289,9 @@ void QDECL Com_Error( int code, const char *fmt, ... ) { Com_Printf ("********************\nERROR: %s\n********************\n", com_errorMessage); SV_Shutdown (va("Server crashed: %s", com_errorMessage)); CL_Disconnect( qtrue ); + VM_Forced_Unload_Start(); CL_FlushMemory( ); + VM_Forced_Unload_Done(); FS_PureServerSetLoadedPaks("", ""); com_errorEntered = qfalse; longjmp (abortframe, -1); @@ -297,7 +299,9 @@ void QDECL Com_Error( int code, const char *fmt, ... ) { SV_Shutdown( "Server didn't have CD" ); if ( com_cl_running && com_cl_running->integer ) { CL_Disconnect( qtrue ); + VM_Forced_Unload_Start(); CL_FlushMemory( ); + VM_Forced_Unload_Done(); com_errorEntered = qfalse; CL_CDDialog(); } else { -- cgit v1.2.3