fixes e38726db5, c5690e726
This commit is contained in:
YoshiRulz 2021-12-03 07:58:05 +10:00
parent a78e3feaf6
commit 477ef2e519
No known key found for this signature in database
GPG Key ID: C4DE31C245353FB7
2 changed files with 2 additions and 2 deletions

View File

@ -40,7 +40,7 @@ namespace BizHawk.Emulation.Cores.Intellivision
// look up hash in gamedb to see what mapper to use
string s_mapper = null;
var gi = Database.CheckDatabase(SHA1Checksum.ComputePrefixedHex(rom.AsSpan(start: 0, length: rom.Length)));
var gi = Database.CheckDatabase(SHA1Checksum.ComputePrefixedHex(rom));
if (gi != null && !gi.GetOptions().TryGetValue("board", out s_mapper)) { throw new Exception("INTV gamedb entries must have a board identifier!"); }
if (gi == null && (rom.Length % 1024) != 0) { throw new Exception("Game is of unusual size but no header entry present and hash not in game db."); }
_mapper = 0;

View File

@ -441,7 +441,7 @@ namespace BizHawk.Emulation.Cores.Nintendo.NES
{
//now that we know we have an iNES header, we can try to ignore it.
var trimmed = file.AsSpan(start: 16, length: file.Length - 32);
var trimmed = file.AsSpan(start: 16, length: file.Length - 16);
hash_sha1 = SHA1Checksum.ComputePrefixedHex(trimmed);
hash_sha1_several.Add(hash_sha1);
hash_md5 = MD5Checksum.ComputePrefixedHex(trimmed);