Author: aandrejevic Date: Sun Sep 29 22:24:46 2013 New Revision: 60460
URL: http://svn.reactos.org/svn/reactos?rev=60460&view=rev Log: [SOFT386] The immediate operand should be fetched before attempting to read the MOD-REG-R/M byte operands.
Modified: branches/ntvdm/lib/soft386/opgroups.c
Modified: branches/ntvdm/lib/soft386/opgroups.c URL: http://svn.reactos.org/svn/reactos/branches/ntvdm/lib/soft386/opgroups.c?rev... ============================================================================== --- branches/ntvdm/lib/soft386/opgroups.c [iso-8859-1] (original) +++ branches/ntvdm/lib/soft386/opgroups.c [iso-8859-1] Sun Sep 29 22:24:46 2013 @@ -384,15 +384,15 @@ return FALSE; }
+ /* Fetch the count */ + if (!Soft386FetchByte(State, &Count)) + { + /* Exception occurred */ + return FALSE; + } + /* Read the operands */ if (!Soft386ReadModrmByteOperands(State, &ModRegRm, &Dummy, &Value)) - { - /* Exception occurred */ - return FALSE; - } - - /* Fetch the count */ - if (!Soft386FetchByte(State, &Count)) { /* Exception occurred */ return FALSE;