From 0f16f3b1917ce5a26e36dbe00218d8c32479915d Mon Sep 17 00:00:00 2001 From: dborth Date: Mon, 20 Jul 2009 07:26:39 +0000 Subject: [PATCH] fix potential crash --- source/ngc/fceuload.cpp | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/source/ngc/fceuload.cpp b/source/ngc/fceuload.cpp index dcbd8b2..a19d28c 100644 --- a/source/ngc/fceuload.cpp +++ b/source/ngc/fceuload.cpp @@ -95,13 +95,15 @@ int GCMemROM(int method, int size) ErrorPrompt("FDS BIOS file is invalid!"); else ErrorPrompt("FDS BIOS file not found!"); - return 0; // BIOS not loaded, do not load game } free(tmpbuffer); } - // load game - if (FDSLoad(romFilename, fceufp)) - romLoaded = true; + if (FDSBIOS[1] != 0) + { + // load game + if (FDSLoad(romFilename, fceufp)) + romLoaded = true; + } } delete fceufp;