src/mess/image.c
| r7852 | r7853 | |
| 806 | 806 | if (slot->err) |
| 807 | 807 | goto done; |
| 808 | 808 | |
| 809 | | /* do we need to reset the CPU? */ |
| 810 | | if ((attotime_compare(timer_get_time(machine), attotime_zero) > 0) && slot->info.reset_on_load) |
| 811 | | mame_schedule_hard_reset(machine); |
| 812 | | |
| 813 | 809 | /* Check if there's a software list defined for this device and use that if we're not creating an image */ |
| 814 | 810 | if ( is_create || !load_software_part( image, path, &slot->software_info_ptr, &slot->software_part_ptr, &slot->full_software_name ) ) |
| 815 | 811 | { |
| r7852 | r7853 | |
| 860 | 856 | done: |
| 861 | 857 | if (slot->err) |
| 862 | 858 | image_clear(slot); |
| 859 | else { |
| 860 | /* do we need to reset the CPU? only schedule it if load/create is successful */ |
| 861 | if ((attotime_compare(timer_get_time(machine), attotime_zero) > 0) && slot->info.reset_on_load) |
| 862 | mame_schedule_hard_reset(machine); |
| 863 | } |
| 864 | |
| 863 | 865 | return slot->err ? INIT_FAIL : INIT_PASS; |
| 864 | 866 | } |
| 865 | 867 | |