[Scummvm-git-logs] scummvm master -> b866d1893e6c4e3f7cd9580c3b35a8d8de6ccafd
SupSuper
noreply at scummvm.org
Sun Apr 7 21:24:10 UTC 2024
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:
b866d1893e VIDEO: Fix Smacker forceSeekToFrame crash when video is stopped
Commit: b866d1893e6c4e3f7cd9580c3b35a8d8de6ccafd
https://github.com/scummvm/scummvm/commit/b866d1893e6c4e3f7cd9580c3b35a8d8de6ccafd
Author: SupSuper (supsuper at gmail.com)
Date: 2024-04-07T22:22:50+01:00
Commit Message:
VIDEO: Fix Smacker forceSeekToFrame crash when video is stopped
Can only set the startTime while the video is playing
Changed paths:
video/smk_decoder.cpp
diff --git a/video/smk_decoder.cpp b/video/smk_decoder.cpp
index 96ae35517f3..058cad61386 100644
--- a/video/smk_decoder.cpp
+++ b/video/smk_decoder.cpp
@@ -491,7 +491,10 @@ void SmackerDecoder::forceSeekToFrame(uint frame) {
}
_lastTimeChange = videoTrack->getFrameTime(frame);
- _startTime = g_system->getMillis() - (_lastTimeChange.msecs() / getRate()).toInt();
+ if (isPlaying()) {
+ _startTime = g_system->getMillis() - (_lastTimeChange.msecs() / getRate()).toInt();
+ }
+ resetPauseStartTime();
}
void SmackerDecoder::readNextPacket() {
More information about the Scummvm-git-logs
mailing list