- Even while I love having the trap/fpu/context code in C, the bugs this switch intro...
authorStefan Ginsberg <stefanginsberg@gmail.com>
Fri, 6 Apr 2012 20:13:33 +0000 (20:13 +0000)
committerStefan Ginsberg <stefanginsberg@gmail.com>
Fri, 6 Apr 2012 20:13:33 +0000 (20:13 +0000)
svn path=/trunk/; revision=56333

reactos/ntoskrnl/ke/i386/cpu.c

index a1c44a8..8e63a9e 100644 (file)
@@ -1323,7 +1323,12 @@ KiFlushNPXState(IN PFLOATING_SAVE_AREA SaveArea)
     if (Thread->NpxState != NPX_STATE_LOADED)
     {
         /* If there's nothing to load, quit */
-        if (!SaveArea) return;
+        if (!SaveArea)
+        {
+            /* Restore interrupt state and return */
+            __writeeflags(EFlags);
+            return;
+        }
 
         /* Need FXSR support for this */
         ASSERT(KeI386FxsrPresent == TRUE);