[Scummvm-git-logs] scummvm master -> 80bca91b30c21d98235dfa6ddadff70763d80422
rvanlaar
roland at rolandvanlaar.nl
Sat Aug 21 19:39:29 UTC 2021
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:
80bca91b30 DIRECTOR: Don't load nonexisting projector movie
Commit: 80bca91b30c21d98235dfa6ddadff70763d80422
https://github.com/scummvm/scummvm/commit/80bca91b30c21d98235dfa6ddadff70763d80422
Author: Roland van Laar (roland at rolandvanlaar.nl)
Date: 2021-08-21T21:39:13+02:00
Commit Message:
DIRECTOR: Don't load nonexisting projector movie
Continue playing the current movie when the one referenced as projector
isn't found. It seems the best option. ScummVM crashes anyway when it switches to a non-existing movie
This resolves a crash in `The Kids Works 2 Demo`. It's a single file D3
movie which contains everything needed to run it.
Changed paths:
engines/director/resource.cpp
diff --git a/engines/director/resource.cpp b/engines/director/resource.cpp
index 2c2887d10d..e963560b44 100644
--- a/engines/director/resource.cpp
+++ b/engines/director/resource.cpp
@@ -154,14 +154,20 @@ void Window::probeMacBinary(MacArchive *archive) {
error("No strings in Projector file");
Common::String sname = name->readPascalString();
+ Common::String moviePath = pathMakeRelative(sname);
+ if (testPath(moviePath)) {
+ _nextMovie.movie = moviePath;
+ warning("Replaced score name with: %s (from %s)", _nextMovie.movie.c_str(), sname.c_str());
- _nextMovie.movie = pathMakeRelative(sname);
- warning("Replaced score name with: %s (from %s)", _nextMovie.movie.c_str(), sname.c_str());
-
- delete _currentMovie;
- _currentMovie = nullptr;
+ delete _currentMovie;
+ _currentMovie = nullptr;
+ } else {
+ warning("Couldn't find score with name: %s", sname.c_str());
+ }
delete name;
+
+
}
}
More information about the Scummvm-git-logs
mailing list