It's done by the core. If the core is missing something, core itself
needs to be fixed.
PicoCartUnload();\r
z80_exit();\r
\r
- if (Pico.sv.data)\r
- free(Pico.sv.data);\r
+ free(Pico.sv.data);\r
+ Pico.sv.data = NULL;\r
+ Pico.sv.start = Pico.sv.end = 0;\r
pevt_dump();\r
}\r
\r
return NULL;
}
-static void sram_reset()
-{
- SRam.data = NULL;
- SRam.start = 0;
- SRam.end = 0;
- SRam.flags = '\0';
- SRam.unused2 = '\0';
- SRam.changed = '\0' ;
- SRam.eeprom_type = '\0';
- SRam.unused3 = '\0';
- SRam.eeprom_bit_cl = '\0';
- SRam.eeprom_bit_in = '\0';
- SRam.eeprom_bit_out = '\0';
- SRam.size = 0;
-}
-
bool retro_load_game(const struct retro_game_info *info)
{
enum media_type_e media_type;
{ 0 },
};
- sram_reset();
-
enum retro_pixel_format fmt = RETRO_PIXEL_FORMAT_RGB565;
if (!environ_cb(RETRO_ENVIRONMENT_SET_PIXEL_FORMAT, &fmt)) {
if (log_cb)