diff --git a/SDL/main.c b/SDL/main.c index bceffe9..5eb27ee 100644 --- a/SDL/main.c +++ b/SDL/main.c @@ -699,6 +699,9 @@ static void rumble(GB_gameboy_t *gb, double amp) static void debugger_interrupt(int ignore) { #ifndef _WIN32 + if (!GB_is_inited(&gb)) { + exit(0); + } if (GB_debugger_is_stopped(&gb)) { pending_command = GB_SDL_QUIT_COMMAND; console_line_ready(); // Force the debugger wait-loop to process the command