[Scummvm-cvs-logs] scummvm master -> b5fb32de5ea2a4f3dd4133c423d666d00f37744f

dreammaster dreammaster at scummvm.org
Wed Oct 15 03:26:53 CEST 2014


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:
b5fb32de5e MADS: Fix to exit game safely when sound driver hasn't been created


Commit: b5fb32de5ea2a4f3dd4133c423d666d00f37744f
    https://github.com/scummvm/scummvm/commit/b5fb32de5ea2a4f3dd4133c423d666d00f37744f
Author: Paul Gilbert (dreammaster at scummvm.org)
Date: 2014-10-14T21:26:00-04:00

Commit Message:
MADS: Fix to exit game safely when sound driver hasn't been created

Changed paths:
    engines/mads/sound.cpp



diff --git a/engines/mads/sound.cpp b/engines/mads/sound.cpp
index 9d0d9c8..d0aa770 100644
--- a/engines/mads/sound.cpp
+++ b/engines/mads/sound.cpp
@@ -42,9 +42,11 @@ SoundManager::SoundManager(MADSEngine *vm, Audio::Mixer *mixer) {
 }
 
 SoundManager::~SoundManager() {
-	_driver->stop();
+	if (_driver) {
+		_driver->stop();
+		delete _driver;
+	}
 
-	delete _driver;
 	delete _opl;
 }
 






More information about the Scummvm-git-logs mailing list