From: Waccoon <105848526+Waccoon@users.noreply.github.com> Date: Thu, 7 Jul 2022 05:25:51 +0000 (-0400) Subject: MiniDump update: MessageBox, nocrashdump X-Git-Tag: 41000~206^2~1 X-Git-Url: https://git.unchartedbackwaters.co.uk/w/?a=commitdiff_plain;h=b1dd4b0e3b433837879c0996d597d9acc1645382;p=francis%2Fwinuae.git MiniDump update: MessageBox, nocrashdump Fixes "OK" button on MiniDump notification by re-enabling UI events before application close. Console -nocrashdump option fixed. --- diff --git a/od-win32/win32.cpp b/od-win32/win32.cpp index d04d6a1f..d532e7a1 100644 --- a/od-win32/win32.cpp +++ b/od-win32/win32.cpp @@ -397,7 +397,7 @@ void target_calibrate_spin(void) if (vp2 > vp + cntlines * 2) break; } -trynext:; +trynext: } if (sc == 0x800000000000) { write_log(_T("Spincount calculation error, spinloop not used.\n"), sc); @@ -7385,9 +7385,11 @@ static void create_dump (struct _EXCEPTION_POINTERS *pExceptionPointers) ShowCursor(TRUE); if (debugfile) log_close(debugfile); - if (isfullscreen () <= 0) { - _stprintf (msg, _T("Crash detected. MiniDump saved as:\n%s\n"), path3); - MessageBox (NULL, msg, _T("Crash"), MB_OK | MB_ICONWARNING | MB_TASKMODAL | MB_SETFOREGROUND); + if (isfullscreen() <= 0) { + all_events_disabled = 0; + struct AmigaMonitor *mon = &AMonitors[0]; + _stprintf(msg, _T("Crash detected. MiniDump saved as:\n%s\n"), path3); + MessageBox(mon->hStatusWnd ? mon->hStatusWnd : NULL, msg, _T("Crash"), MB_OK | MB_ICONWARNING | MB_TASKMODAL | MB_SETFOREGROUND); } ExitProcess(0); } @@ -7402,7 +7404,7 @@ static void create_dump (struct _EXCEPTION_POINTERS *pExceptionPointers) LONG WINAPI WIN32_ExceptionFilter (struct _EXCEPTION_POINTERS * pExceptionPointers, DWORD ec) { if (nocrashdump || isfullscreen() > 0) - EXCEPTION_CONTINUE_SEARCH; + return EXCEPTION_CONTINUE_SEARCH; write_log (_T("EVALEXCEPTION %08x!\n"), ec); create_dump (pExceptionPointers); return EXCEPTION_CONTINUE_SEARCH;