From e199d943e0fccb294217d2e63d470da1a5b1110a Mon Sep 17 00:00:00 2001 From: myT Date: Thu, 20 Apr 2017 03:28:50 +0200 Subject: [PATCH] fixed calls to OutputDebugStringA/W being considered a crash --- code/win32/win_exception.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/code/win32/win_exception.cpp b/code/win32/win_exception.cpp index bcba286..1b3edd7 100644 --- a/code/win32/win_exception.cpp +++ b/code/win32/win_exception.cpp @@ -387,6 +387,11 @@ static qbool exc_exitCalled = qfalse; LONG CALLBACK WIN_HandleException( EXCEPTION_POINTERS* ep ) { + // Allow calls to OutputDebugStringA/W. + if (ep != NULL && ep->ExceptionRecord != NULL && + ep->ExceptionRecord->ExceptionCode == DBG_PRINTEXCEPTION_C) + return EXCEPTION_CONTINUE_SEARCH; + __try { WIN_EndTimePeriod(); } __except(EXCEPTION_EXECUTE_HANDLER) {}