Roderick Colenbrander : wined3d: Fix recursive ENTER_GL in UpdateSurface.

Alexandre Julliard julliard at winehq.org
Mon Oct 20 08:00:30 CDT 2008


Module: wine
Branch: master
Commit: 47372928b8fcc978954523bc8e6cb59b0c5941fc
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=47372928b8fcc978954523bc8e6cb59b0c5941fc

Author: Roderick Colenbrander <thunderbird2k at gmx.net>
Date:   Sun Oct 19 00:05:10 2008 +0000

wined3d: Fix recursive ENTER_GL in UpdateSurface.

---

 dlls/wined3d/device.c |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c
index 185dbef..9a35d18 100644
--- a/dlls/wined3d/device.c
+++ b/dlls/wined3d/device.c
@@ -5880,11 +5880,11 @@ static HRESULT  WINAPI  IWineD3DDeviceImpl_UpdateSurface(IWineD3DDevice *iface,
 
     ActivateContext(This, This->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD);
 
-    ENTER_GL();
-
     if (GL_SUPPORT(ARB_MULTITEXTURE)) {
+        ENTER_GL();
         GL_EXTCALL(glActiveTextureARB(GL_TEXTURE0_ARB));
         checkGLcall("glActiveTextureARB");
+        LEAVE_GL();
     }
 
     /* Make sure the surface is loaded and up to date */
@@ -5924,6 +5924,8 @@ static HRESULT  WINAPI  IWineD3DDeviceImpl_UpdateSurface(IWineD3DDevice *iface,
         FIXME("Surfaces has no allocated memory, but should be an in memory only surface\n");
     }
 
+    ENTER_GL();
+
     /* TODO: Cube and volume support */
     if(rowoffset != 0){
         /* not a whole row so we have to do it a line at a time */




More information about the wine-cvs mailing list