diff options
author | Martin Kiewitz | 2010-07-20 12:50:13 +0000 |
---|---|---|
committer | Martin Kiewitz | 2010-07-20 12:50:13 +0000 |
commit | 6ebcb5326585a3ec2e2708f8a943c86ce6c9d40f (patch) | |
tree | ed49a6a4c8b0ed7d7a5d34c7e839abb0c8dde8e2 | |
parent | 0b3f816c8b13d1cbc2b121461bdcd8aa2068ddde (diff) | |
download | scummvm-rg350-6ebcb5326585a3ec2e2708f8a943c86ce6c9d40f.tar.gz scummvm-rg350-6ebcb5326585a3ec2e2708f8a943c86ce6c9d40f.tar.bz2 scummvm-rg350-6ebcb5326585a3ec2e2708f8a943c86ce6c9d40f.zip |
SCI: fix regression of r51060
svn-id: r51062
-rw-r--r-- | engines/sci/engine/vm.cpp | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/engines/sci/engine/vm.cpp b/engines/sci/engine/vm.cpp index a56eab4ddf..9ec8842ab3 100644 --- a/engines/sci/engine/vm.cpp +++ b/engines/sci/engine/vm.cpp @@ -928,10 +928,17 @@ static void callKernelFunc(EngineState *s, int kernelCallNr, int argc) { error("[VM] k%s: signature mismatch via method %s::%s (script %d, localCall %x)", kernelSubCall.name, originReply.objectName.c_str(), originReply.methodName.c_str(), originReply.scriptNr, originReply.localCallOffset); } // FIXME: implement some real workaround type logic - ignore call, still do call etc. - if (workaround.segment == 2) + switch (workaround.segment) { + case 0: // don't do kernel call, leave acc alone + return; + case 1: // call kernel anyway + break; + case 2: // don't do kernel call, fake acc s->r_acc = make_reg(0, workaround.offset); - if (workaround.segment) return; + default: + error("unknown workaround type"); + } } if (!kernelSubCall.function) error("[VM] k%s: subfunction-id %d requested, but not available", kernelCall.name, subId); |