diff options
author | Matthew Hoops | 2012-10-03 10:44:57 -0400 |
---|---|---|
committer | Matthew Hoops | 2012-10-03 10:45:43 -0400 |
commit | f0091af6b514938be8778d4c6943b18c81b3d50a (patch) | |
tree | 3ddc44286d4a6ef1c853e805f243dc8c11a5e0a8 | |
parent | b50f5a4cde4b6e3549d0c0139b52079c092d0529 (diff) | |
download | scummvm-rg350-f0091af6b514938be8778d4c6943b18c81b3d50a.tar.gz scummvm-rg350-f0091af6b514938be8778d4c6943b18c81b3d50a.tar.bz2 scummvm-rg350-f0091af6b514938be8778d4c6943b18c81b3d50a.zip |
AUDIO: Don't allow skipping negative times in skipSamples()
-rw-r--r-- | audio/decoders/quicktime.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/audio/decoders/quicktime.cpp b/audio/decoders/quicktime.cpp index 35210eb020..0588650ec6 100644 --- a/audio/decoders/quicktime.cpp +++ b/audio/decoders/quicktime.cpp @@ -395,9 +395,9 @@ AudioStream *QuickTimeAudioDecoder::QuickTimeAudioTrack::readAudioChunk(uint chu } void QuickTimeAudioDecoder::QuickTimeAudioTrack::skipSamples(const Timestamp &length, AudioStream *stream) { - uint32 sampleCount = length.convertToFramerate(getRate()).totalNumberOfFrames(); + int32 sampleCount = length.convertToFramerate(getRate()).totalNumberOfFrames(); - if (sampleCount == 0) + if (sampleCount <= 0) return; if (isStereo()) |