aboutsummaryrefslogtreecommitdiff
path: root/engines/saga/sndres.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'engines/saga/sndres.cpp')
-rw-r--r--engines/saga/sndres.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/engines/saga/sndres.cpp b/engines/saga/sndres.cpp
index d6114b3fc4..18f410bd90 100644
--- a/engines/saga/sndres.cpp
+++ b/engines/saga/sndres.cpp
@@ -101,7 +101,12 @@ SndRes::~SndRes() {
}
void SndRes::setVoiceBank(int serial) {
- if (_voiceSerial == serial) return;
+ if (_voiceSerial == serial)
+ return;
+
+ // If there are no voice files present, don't set the voice bank
+ if (!_vm->_voiceFilesExist)
+ return;
// Close previous voice bank file
if (_voiceSerial >= 0 && _voiceContext->file->isOpen())