From: Aleksandar Andrejevic Date: Fri, 5 Jun 2015 20:03:55 +0000 (+0000) Subject: [FAST486] X-Git-Tag: backups/colins-printing-for-freedom@73041~15^2~196 X-Git-Url: https://git.reactos.org/?p=reactos.git;a=commitdiff_plain;h=44d853be5b73860bb7f4e842750728745e68060b [FAST486] opgroups.c: We shouldn't restore SP in the opcode handler as that might interfere with triple faults. Also, in this case it's also wrong because the exception procedure already restores the stack pointer. common.c: Fix a comment, no code changes. svn path=/trunk/; revision=68027 --- diff --git a/reactos/lib/fast486/common.c b/reactos/lib/fast486/common.c index a5deaf86eb8..5827339e57d 100644 --- a/reactos/lib/fast486/common.c +++ b/reactos/lib/fast486/common.c @@ -579,7 +579,7 @@ Fast486ExceptionWithErrorCode(PFAST486_STATE State, /* Restore the IP to the saved IP */ State->InstPtr = State->SavedInstPtr; - /* Restore the SP to the saved SP */ + /* Restore the SP to the saved SP */ State->GeneralRegs[FAST486_REG_ESP] = State->SavedStackPtr; /* Get the interrupt vector */ diff --git a/reactos/lib/fast486/opgroups.c b/reactos/lib/fast486/opgroups.c index e3e6ba7ed2c..65dd6864fd2 100644 --- a/reactos/lib/fast486/opgroups.c +++ b/reactos/lib/fast486/opgroups.c @@ -494,10 +494,7 @@ FAST486_OPCODE_HANDLER(Fast486OpcodeGroup8F) if (!Fast486ParseModRegRm(State, AddressSize, &ModRegRm)) { - /* Exception occurred - restore SP */ - if (OperandSize) State->GeneralRegs[FAST486_REG_ESP].Long -= sizeof(ULONG); - else State->GeneralRegs[FAST486_REG_ESP].LowWord -= sizeof(USHORT); - + /* Exception occurred */ return; }