ddraw: Fix executebuffer branching with non-zero offset.
Fixes a crash in Moto Racer 2.
This commit is contained in:
parent
1079f37407
commit
4981eda895
|
@ -524,12 +524,18 @@ IDirect3DExecuteBufferImpl_Execute(IDirect3DExecuteBufferImpl *This,
|
|||
if ((This->data.dsStatus.dwStatus & ci->dwMask) == ci->dwValue) {
|
||||
if (!ci->bNegate) {
|
||||
TRACE(" Branch to %d\n", ci->dwOffset);
|
||||
instr = (char*)current + ci->dwOffset;
|
||||
if (ci->dwOffset) {
|
||||
instr = (char*)current + ci->dwOffset;
|
||||
break;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
if (ci->bNegate) {
|
||||
TRACE(" Branch to %d\n", ci->dwOffset);
|
||||
instr = (char*)current + ci->dwOffset;
|
||||
if (ci->dwOffset) {
|
||||
instr = (char*)current + ci->dwOffset;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue