Only check matching assembly versions on Windows

Assembly version check shouldn't be necessary if installed with a package
manager.
This commit is contained in:
YoshiRulz 2019-08-12 02:20:09 +10:00
parent 76df4758db
commit 080343f902
No known key found for this signature in database
GPG Key ID: C4DE31C245353FB7
1 changed files with 2 additions and 1 deletions

View File

@ -96,7 +96,8 @@ namespace BizHawk.Client.EmuHawk
// this check has to be done VERY early. i stepped through a debug build with wrong .dll versions purposely used,
// and there was a TypeLoadException before the first line of SubMain was reached (some static ColorType init?)
// zero 25-dec-2012 - only do for public builds. its annoying during development
if (!VersionInfo.DeveloperBuild)
// and don't bother when installed from a package manager i.e. not Windows --yoshi
if (!VersionInfo.DeveloperBuild && EXE_PROJECT.OSTailoredCode.CurrentOS == EXE_PROJECT.OSTailoredCode.DistinctOS.Windows)
{
var thisversion = typeof(Program).Assembly.GetName().Version;
var utilversion = Assembly.Load(new AssemblyName("Bizhawk.Client.Common")).GetName().Version;