Search
lxdream.org :: lxdream :: r768:b2a54f6864eb
lxdream 0.9.1
released Jun 29
Download Now
changeset768:b2a54f6864eb
parent767:53dc977f8f25
child769:f7f62bea4cad
authornkeynes
dateThu Jul 24 07:27:48 2008 +0000 (15 years ago)
Halt emulation after reporting an error
src/util.c
1.1 --- a/src/util.c Thu Jul 24 02:31:56 2008 +0000
1.2 +++ b/src/util.c Thu Jul 24 07:27:48 2008 +0000
1.3 @@ -30,6 +30,7 @@
1.4 #include <png.h>
1.5 #include "dream.h"
1.6 #include "display.h"
1.7 +#include "dreamcast.h"
1.8 #include "gui.h"
1.9 #include "sh4/sh4.h"
1.10
1.11 @@ -320,6 +321,11 @@
1.12 if( level <= EMIT_ERR ) {
1.13 if( gui_error_dialog( text ) ) {
1.14 g_free(text);
1.15 + // If we're running, halt on error to avoid potentially flooding
1.16 + // the user with error messages.
1.17 + if( dreamcast_is_running() ) {
1.18 + dreamcast_stop();
1.19 + }
1.20 return;
1.21 }
1.22 }
.