Index: /trunk/src/VBox/Devices/Graphics/DevVGA.cpp
===================================================================
--- /trunk/src/VBox/Devices/Graphics/DevVGA.cpp	(revision 51628)
+++ /trunk/src/VBox/Devices/Graphics/DevVGA.cpp	(revision 51629)
@@ -4948,6 +4948,7 @@
 
     Assert(pInterface);
-    Assert(pThis->pDrv);
-    Assert(pThis->pDrv->pu8Data);
+
+    int rc = PDMCritSectEnter(&pThis->CritSect, VERR_SEM_BUSY);
+    AssertRC(rc);
 
     /* Check if there is something to do at all. */
@@ -4958,9 +4959,10 @@
         LogFlow(("vgaPortUpdateDisplayRect: nothing to do fRender is false.\n"));
 #endif /* DEBUG_sunlover */
+        PDMCritSectLeave(&pThis->CritSect);
         return;
     }
 
-    int rc = PDMCritSectEnter(&pThis->CritSect, VERR_SEM_BUSY);
-    AssertRC(rc);
+    Assert(pThis->pDrv);
+    Assert(pThis->pDrv->pu8Data);
 
     /* Correct negative x and y coordinates. */
