|
|
|
@@ -312,9 +312,9 @@ int state_read(nes* sys, const void* mem, int mem_size) { |
|
|
|
if ((ptr + size) > end) { |
|
|
|
result = -1; |
|
|
|
fprintf(stderr, |
|
|
|
"Unusually large chunk: %.4s: +%"PRIu64"\n", |
|
|
|
"Unusually large chunk: %.4s: +%d\n", |
|
|
|
(char*)&tag, |
|
|
|
((ptr + size) - end)); |
|
|
|
(int)((ptr + size) - end)); |
|
|
|
break; |
|
|
|
} |
|
|
|
|
|
|
|
@@ -359,27 +359,27 @@ int state_read(nes* sys, const void* mem, int mem_size) { |
|
|
|
} |
|
|
|
|
|
|
|
if (0 == result) { |
|
|
|
if (!(loaded | Component_CPU)) { |
|
|
|
if (!(loaded & Component_CPU)) { |
|
|
|
result = -1; |
|
|
|
fprintf(stderr, "Missing %s state\n", "CPU"); |
|
|
|
} |
|
|
|
|
|
|
|
if (!(loaded | Component_PPU)) { |
|
|
|
if (!(loaded & Component_PPU)) { |
|
|
|
result = -1; |
|
|
|
fprintf(stderr, "Missing %s state\n", "PPU"); |
|
|
|
} |
|
|
|
|
|
|
|
if (!(loaded | Component_APU)) { |
|
|
|
if (!(loaded & Component_APU)) { |
|
|
|
result = -1; |
|
|
|
fprintf(stderr, "Missing %s state\n", "APU"); |
|
|
|
} |
|
|
|
|
|
|
|
if (!(loaded | Component_RAM)) { |
|
|
|
if (!(loaded & Component_RAM)) { |
|
|
|
result = -1; |
|
|
|
fprintf(stderr, "Missing %s state\n", "RAM"); |
|
|
|
} |
|
|
|
|
|
|
|
if (!(loaded | Component_Mapper)) { |
|
|
|
if (!(loaded & Component_Mapper)) { |
|
|
|
result = -1; |
|
|
|
fprintf(stderr, "Missing %s state\n", "Mapper"); |
|
|
|
} |
|
|
|
|