aboutsummaryrefslogtreecommitdiff
path: root/engines/sci/engine
diff options
context:
space:
mode:
authorLars Skovlund2010-09-12 18:13:14 +0000
committerLars Skovlund2010-09-12 18:13:14 +0000
commitde6555663d1c19b6658601df4b987d605183aeef (patch)
tree3bc7695fffa44d9e2ddafca70ddc78431bb66d18 /engines/sci/engine
parent161b2e6c798b1499af0a042a73f13c86490b984d (diff)
downloadscummvm-rg350-de6555663d1c19b6658601df4b987d605183aeef.tar.gz
scummvm-rg350-de6555663d1c19b6658601df4b987d605183aeef.tar.bz2
scummvm-rg350-de6555663d1c19b6658601df4b987d605183aeef.zip
Workaround for bug #038837: HOYLE3: EGA/VGA Crashes. Needs further
investigation and a proper fix post-release svn-id: r52688
Diffstat (limited to 'engines/sci/engine')
-rw-r--r--engines/sci/engine/script.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/engines/sci/engine/script.cpp b/engines/sci/engine/script.cpp
index 9561d337ef..719d01162c 100644
--- a/engines/sci/engine/script.cpp
+++ b/engines/sci/engine/script.cpp
@@ -310,6 +310,16 @@ void Script::incrementLockers() {
void Script::decrementLockers() {
if (_lockers > 0)
_lockers--;
+
+ // WORKAROUND for bug #3038837: HOYLE3: EGA/VGA Crashes
+ // This is caused by script 0 lockers reaching zero. Since
+ // this should never happen, I'm confident in making this a
+ // non-specific fix.
+ //
+ // TODO: Figure out why this happens, and fix it properly!
+ if (_nr == 0 && _lockers == 0)
+ _lockers++;
+
}
int Script::getLockers() const {