aboutsummaryrefslogtreecommitdiff
path: root/engines/scumm
diff options
context:
space:
mode:
authorTravis Howell2007-06-06 03:38:45 +0000
committerTravis Howell2007-06-06 03:38:45 +0000
commitc8259673b7753b288a4ccb391f7435942d741b6c (patch)
treeaff4930b190c9a883b0dae008ee746b33739e572 /engines/scumm
parent735530bdc8908aa9d900366c9c6e674a3797b269 (diff)
downloadscummvm-rg350-c8259673b7753b288a4ccb391f7435942d741b6c.tar.gz
scummvm-rg350-c8259673b7753b288a4ccb391f7435942d741b6c.tar.bz2
scummvm-rg350-c8259673b7753b288a4ccb391f7435942d741b6c.zip
Fix possible crash issue, if music volume was set by 3DO versions of HE games.
svn-id: r27125
Diffstat (limited to 'engines/scumm')
-rw-r--r--engines/scumm/he/script_v60he.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/engines/scumm/he/script_v60he.cpp b/engines/scumm/he/script_v60he.cpp
index 8bbea49bd5..baee2f3e49 100644
--- a/engines/scumm/he/script_v60he.cpp
+++ b/engines/scumm/he/script_v60he.cpp
@@ -1090,7 +1090,7 @@ void ScummEngine_v60he::o60_readFile() {
int val;
// Fatty Bear uses positive values
- if ((_game.platform == Common::kPlatformPC) && (_game.id == GID_FBEAR))
+ if (_game.platform == Common::kPlatformPC && _game.id == GID_FBEAR)
size = -size;
assert(_hInFileTable[slot]);
@@ -1120,7 +1120,7 @@ void ScummEngine_v60he::o60_writeFile() {
int slot = pop();
// Fatty Bear uses positive values
- if ((_game.platform == Common::kPlatformPC) && (_game.id == GID_FBEAR))
+ if (_game.platform == Common::kPlatformPC && _game.id == GID_FBEAR)
size = -size;
assert(_hOutFileTable[slot]);
@@ -1139,7 +1139,9 @@ void ScummEngine_v60he::o60_soundOps() {
switch (subOp) {
case 222:
- _imuse->setMusicVolume(arg);
+ if (_imuse) {
+ _imuse->setMusicVolume(arg);
+ }
break;
case 223:
// WORKAROUND: For error in room script 228 (room 2) of fbear.