Mercurial > repos > blastem
diff romdb.c @ 1503:a763523dadf4 segacd
Added code for initializing a combined Genesis + Sega CD system when a Sega CD ISO is loaded
author | Michael Pavone <pavone@retrodev.com> |
---|---|
date | Wed, 13 Dec 2017 09:44:41 -0800 |
parents | 14a2834d010c |
children | 5dacaef602a7 |
line wrap: on
line diff
--- a/romdb.c Tue Dec 12 09:44:33 2017 -0800 +++ b/romdb.c Wed Dec 13 09:44:41 2017 -0800 @@ -33,11 +33,14 @@ return "SRAM"; } -tern_node *load_rom_db() +tern_node *get_rom_db() { - tern_node *db = parse_bundled_config("rom.db"); + static tern_node *db; if (!db) { - fatal_error("Failed to load ROM DB\n"); + db = parse_bundled_config("rom.db"); + if (!db) { + fatal_error("Failed to load ROM DB\n"); + } } return db; }