Snes9x - Fix BPS patch support. (ArtiiP) (#838)

This commit is contained in:
bladeoner 2019-04-11 01:03:00 +02:00 committed by dborth
parent 4e057ed7b4
commit 11093a7e1a

View File

@ -3918,6 +3918,7 @@ static bool8 ReadBPSPatch (Stream *r, long, int32 &rom_size)
if(patch_crc32 != pp_crc32) { delete[] data; return false; } //patch is corrupted
if(!Settings.IgnorePatchChecksum && rom_crc32 != source_crc32) { delete[] data; return false; } //patch is for a different ROM
XPSdecode(data, addr, size);
uint32 target_size = XPSdecode(data, addr, size);
uint32 metadata_size = XPSdecode(data, addr, size);
addr += metadata_size;