1.1 --- a/src/dreamcast.c Thu Jul 24 02:30:37 2008 +0000
1.2 +++ b/src/dreamcast.c Sun Aug 24 01:58:09 2008 +0000
1.5 void dreamcast_configure( )
1.7 + const char *bios_path = lxdream_get_config_value(CONFIG_BIOS_PATH);
1.8 + const char *flash_path = lxdream_get_config_value(CONFIG_FLASH_PATH);
1.10 dreamcast_register_module( &eventq_module );
1.11 /* Register the memory framework */
1.12 dreamcast_register_module( &mem_module );
1.14 mem_create_ram_region( 0x00800000, 2 MB, MEM_REGION_AUDIO );
1.15 mem_create_ram_region( 0x00703000, 8 KB, MEM_REGION_AUDIO_SCRATCH );
1.16 mem_create_ram_region( 0x05000000, 8 MB, MEM_REGION_VIDEO );
1.17 - dreamcast_has_bios = mem_load_rom( lxdream_get_config_value(CONFIG_BIOS_PATH),
1.18 - 0x00000000, 0x00200000, 0x89f2b1a1,
1.19 - MEM_REGION_BIOS );
1.20 + dreamcast_has_bios = mem_load_rom( bios_path, 0x00000000, 0x00200000, 0x89f2b1a1, MEM_REGION_BIOS );
1.21 mem_create_ram_region( 0x00200000, 0x00020000, MEM_REGION_FLASH );
1.22 - mem_load_block( lxdream_get_config_value(CONFIG_FLASH_PATH),
1.23 - 0x00200000, 0x00020000 );
1.24 + if( flash_path != NULL && flash_path[0] != '\0' ) {
1.25 + mem_load_block( flash_path, 0x00200000, 0x00020000 );
1.27 dreamcast_has_flash = TRUE;
1.29 /* Load in the rest of the core modules */
1.32 void dreamcast_config_changed(void)
1.34 - dreamcast_has_bios = mem_load_rom( lxdream_get_config_value(CONFIG_BIOS_PATH),
1.35 - 0x00000000, 0x00200000, 0x89f2b1a1,
1.36 - MEM_REGION_BIOS );
1.37 - mem_load_block( lxdream_get_config_value(CONFIG_FLASH_PATH),
1.38 - 0x00200000, 0x00020000 );
1.39 + const char *bios_path = lxdream_get_config_value(CONFIG_BIOS_PATH);
1.40 + const char *flash_path = lxdream_get_config_value(CONFIG_FLASH_PATH);
1.41 + dreamcast_has_bios = mem_load_rom( bios_path, 0x00000000, 0x00200000, 0x89f2b1a1, MEM_REGION_BIOS );
1.42 + if( flash_path != NULL && flash_path[0] != '\0' ) {
1.43 + mem_load_block( flash_path, 0x00200000, 0x00020000 );
1.47 void dreamcast_save_flash()