[PATCH 5/5] wined3d: Initialize "context[0]" in IWineD3DDeviceImpl_CreateSwapChain() when not using OpenGL (Valgrind).

Henri Verbeet hverbeet at codeweavers.com
Wed Nov 4 03:37:17 CST 2009


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

diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c
index e6931ea..a5a6c2e 100644
--- a/dlls/wined3d/device.c
+++ b/dlls/wined3d/device.c
@@ -1211,6 +1211,10 @@ static HRESULT WINAPI IWineD3DDeviceImpl_CreateSwapChain(IWineD3DDevice *iface,
                 object->win_handle, object->context[0]->glCtx);
         }
     }
+    else
+    {
+        object->context[0] = NULL;
+    }
 
    /*********************
    * Create the back, front and stencil buffers
-- 
1.6.4.4




More information about the wine-patches mailing list