[Scummvm-git-logs] scummvm master -> 84d2f0db8f75ca8003f2e72a6c977e8f23f667e7
moralrecordings
code at moral.net.au
Tue Jun 1 14:05:37 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:
84d2f0db8f DIRECTOR: Add sanity checks for starting/stopping video
Commit: 84d2f0db8f75ca8003f2e72a6c977e8f23f667e7
https://github.com/scummvm/scummvm/commit/84d2f0db8f75ca8003f2e72a6c977e8f23f667e7
Author: Scott Percival (code at moral.net.au)
Date: 2021-06-01T22:04:45+08:00
Commit Message:
DIRECTOR: Add sanity checks for starting/stopping video
Changed paths:
engines/director/castmember.cpp
diff --git a/engines/director/castmember.cpp b/engines/director/castmember.cpp
index 879a0f8732..0afd7c4f2b 100644
--- a/engines/director/castmember.cpp
+++ b/engines/director/castmember.cpp
@@ -346,6 +346,11 @@ bool DigitalVideoCastMember::isModified() {
void DigitalVideoCastMember::startVideo(Channel *channel) {
_channel = channel;
+ if (!_video || !_video->isVideoLoaded()) {
+ warning("DigitalVideoCastMember::startVideo: No video decoder");
+ return;
+ }
+
if (_pausedAtStart) {
_getFirstFrame = true;
} else {
@@ -367,6 +372,11 @@ void DigitalVideoCastMember::startVideo(Channel *channel) {
}
void DigitalVideoCastMember::stopVideo(Channel *channel) {
+ if (!_video || !_video->isVideoLoaded()) {
+ warning("DigitalVideoCastMember::stopVideo: No video decoder");
+ return;
+ }
+
_video->stop();
debugC(2, kDebugImages, "STOPPING VIDEO %s", _filename.c_str());
More information about the Scummvm-git-logs
mailing list