aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--engines/scumm/smush/saud_channel.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/engines/scumm/smush/saud_channel.cpp b/engines/scumm/smush/saud_channel.cpp
index 7a0f146e10..902934f943 100644
--- a/engines/scumm/smush/saud_channel.cpp
+++ b/engines/scumm/smush/saud_channel.cpp
@@ -172,9 +172,10 @@ bool SaudChannel::appendData(Chunk &b, int32 size) {
byte *SaudChannel::getSoundData() {
byte *tmp = _sbuffer;
- assert(_dataSize > 0);
- if (!_keepSize)
+ if (!_keepSize) {
+ assert(_dataSize > 0);
_dataSize -= _sbufferSize;
+ }
_sbuffer = 0;
_sbufferSize = 0;