(svn r23119) -Fix: [Win32] Don't show a crash/assertion message box for a GUI-less video driver.

This commit is contained in:
michi_cc
2011-11-04 23:47:00 +00:00
parent 2de0383538
commit ee6e8ea36b
3 changed files with 12 additions and 1 deletions

View File

@@ -25,6 +25,7 @@
#include "../../strings_func.h"
#include "../../gamelog.h"
#include "../../saveload/saveload.h"
#include "../../video/video_driver.hpp"
#include <windows.h>
#include <signal.h>
@@ -526,7 +527,7 @@ static LONG WINAPI ExceptionHandler(EXCEPTION_POINTERS *ep)
/* Close any possible log files */
CloseConsoleLogIfActive();
if (_safe_esp != NULL) {
if ((_video_driver == NULL || _video_driver->HasGUI()) && _safe_esp != NULL) {
#ifdef _M_AMD64
ep->ContextRecord->Rip = (DWORD64)ShowCrashlogWindow;
ep->ContextRecord->Rsp = (DWORD64)_safe_esp;