summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
author etabeta78 <etabeta78@users.noreply.github.com>2015-01-19 11:48:33 +0100
committer etabeta78 <etabeta78@users.noreply.github.com>2015-01-19 11:48:33 +0100
commita87d6d044259d850f1e4e40b265fff0cf4986f57 (patch)
treee1372ed67f4cce8c0f593ee6636baa68c4208dfd
parent0641ab831c824f8d9a66301534a22b6ea0e4da59 (diff)
ui: fixed bug where software items that shall create new image
devices (e.g., passthru carts) or new slot options, failed to do so when loaded through the File Manager in the internal UI. [Fabio Priuli] out of whatsnew: to see the bug, try to launch with previous code nes with no options, then mount ggenie cart and, after the reboot, try to mount any other game in the -cart2 media switch. System will reboot, but only ggenie remains mounted. Alternatively, launch c64 and manually mount cbmieee from the UI. After reboot the serial slot options in the Slot Options menu are not configurable, because the core was not "informed" of their addition, and any cart you try to mount in -cart2 will be ignored, because the new media switch is not acknowledged by the core. Once again, from command line everything was fine, and thus the issue was hard to spot :)
-rw-r--r--src/emu/emuopts.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/emu/emuopts.c b/src/emu/emuopts.c
index e9651110ecc..1b34b86518e 100644
--- a/src/emu/emuopts.c
+++ b/src/emu/emuopts.c
@@ -278,6 +278,8 @@ void emu_options::update_slot_options()
}
}
}
+ while (add_slot_options(false));
+ add_device_options(false);
}
@@ -365,8 +367,6 @@ bool emu_options::parse_slot_devices(int argc, char *argv[], astring &error_stri
do {
num = options_count();
update_slot_options();
- while (add_slot_options(false));
- add_device_options(false);
result = core_options::parse_command_line(argc, argv, OPTION_PRIORITY_CMDLINE, error_string);
} while (num != options_count());
@@ -502,8 +502,6 @@ void emu_options::set_system_name(const char *name)
do {
num = options_count();
update_slot_options();
- while (add_slot_options(false));
- add_device_options(false);
} while(num != options_count());
}
}