X-Git-Url: https://notaz.gp2x.de/cgi-bin/gitweb.cgi?a=blobdiff_plain;ds=inline;f=platform%2Fgizmondo%2Femu.c;h=9a285536955b3d2c698de445822a30075863d829;hb=1ca2ea4f60d990a4240a387fdde78a87f77f30f1;hp=152c64844a22fd720cbd0f4c2637210d6d8ad659;hpb=1f4e9f147fc079f0efe4c4f95c0c9549d3b41553;p=picodrive.git diff --git a/platform/gizmondo/emu.c b/platform/gizmondo/emu.c index 152c648..9a28553 100644 --- a/platform/gizmondo/emu.c +++ b/platform/gizmondo/emu.c @@ -109,19 +109,8 @@ void emu_Deinit(void) SRam.changed = 0; } - if (!(currentConfig.EmuOpt & 0x20)) { - FILE *f = fopen(PicoConfigFile, "r+b"); - if (!f) emu_WriteConfig(0); - else { - // if we already have config, reload it, except last ROM - fseek(f, sizeof(currentConfig.lastRomFile), SEEK_SET); - fread(¤tConfig.EmuOpt, 1, sizeof(currentConfig) - sizeof(currentConfig.lastRomFile), f); - fseek(f, 0, SEEK_SET); - fwrite(¤tConfig, 1, sizeof(currentConfig), f); - fflush(f); - fclose(f); - } - } + if (!(currentConfig.EmuOpt & 0x20)) + config_writelrom(PicoConfigFile); PicoExit(); }