give more secure hashes higher priority than less secure ones
This commit is contained in:
parent
d829f19bca
commit
9092a38a82
|
@ -220,8 +220,8 @@ namespace BizHawk.Emulation.Common
|
||||||
{
|
{
|
||||||
acquire.WaitOne();
|
acquire.WaitOne();
|
||||||
|
|
||||||
var hashCRC32 = CRC32Checksum.ComputeDigestHex(romData);
|
var hashSHA1 = SHA1Checksum.ComputeDigestHex(romData);
|
||||||
if (DB.TryGetValue(hashCRC32, out var cgi))
|
if (DB.TryGetValue(hashSHA1, out var cgi))
|
||||||
{
|
{
|
||||||
return new GameInfo(cgi);
|
return new GameInfo(cgi);
|
||||||
}
|
}
|
||||||
|
@ -232,8 +232,8 @@ namespace BizHawk.Emulation.Common
|
||||||
return new GameInfo(cgi);
|
return new GameInfo(cgi);
|
||||||
}
|
}
|
||||||
|
|
||||||
var hashSHA1 = SHA1Checksum.ComputeDigestHex(romData);
|
var hashCRC32 = CRC32Checksum.ComputeDigestHex(romData);
|
||||||
if (DB.TryGetValue(hashSHA1, out cgi))
|
if (DB.TryGetValue(hashCRC32, out cgi))
|
||||||
{
|
{
|
||||||
return new GameInfo(cgi);
|
return new GameInfo(cgi);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue