[Scummvm-git-logs] scummvm master -> 799a9eb9428db1d749444aff58456b10ffc62318

sluicebox noreply at scummvm.org
Tue May 3 19:44:51 UTC 2022


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
799a9eb942 BASE: Clear MD5 cache when upgrading to engine id


Commit: 799a9eb9428db1d749444aff58456b10ffc62318
    https://github.com/scummvm/scummvm/commit/799a9eb9428db1d749444aff58456b10ffc62318
Author: sluicebox (22204938+sluicebox at users.noreply.github.com)
Date: 2022-05-03T15:43:35-04:00

Commit Message:
BASE: Clear MD5 cache when upgrading to engine id

Fixes assigning the wrong game id when upgrading a target to have
an engine id. If a game had been run earlier ran then its checksums
could still be cached. If both games were from the same engine then
advanced detector could select the previous game.

Fixes bug: #13458

Changed paths:
    base/plugins.cpp


diff --git a/base/plugins.cpp b/base/plugins.cpp
index 3d01dba0357..662cd3e573d 100644
--- a/base/plugins.cpp
+++ b/base/plugins.cpp
@@ -943,6 +943,8 @@ void EngineManager::upgradeTargetForEngineId(const Common::String &target) const
 		MetaEngineDetection &metaEngine = plugin->get<MetaEngineDetection>();
 		// set debug flags before call detectGames
 		DebugMan.addAllDebugChannels(metaEngine.getDebugChannels());
+		// Clear md5 cache before detection starts
+		MD5Man.clear();
 		DetectedGames candidates = metaEngine.detectGames(files);
 		if (candidates.empty()) {
 			warning("No games supported by the engine '%s' were found in path '%s' when upgrading target '%s'",




More information about the Scummvm-git-logs mailing list