WineD3D: Properly initialize a variable

Stefan Dösinger stefan at codeweavers.com
Sat Aug 26 17:37:56 CDT 2006


In IWineD3DSurfaceImpl_SaveSnapshot tmpTexture might be uninitialized, which 
might lead to accidentally binding the 0 texture.
-------------- next part --------------
From nobody Mon Sep 17 00:00:00 2001
From: Stefan Doesinger <stefan at codeweavers.com>
Date: Sun Aug 27 00:36:19 2006 +0200
Subject: [PATCH] WineD3D: Properly initialize a variable

---

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

1a264c5fd2a7d9e7c1e6b82a5785606333ff0282
diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c
index 0e0e6dd..fe4fd29 100644
--- a/dlls/wined3d/surface.c
+++ b/dlls/wined3d/surface.c
@@ -2026,7 +2026,7 @@ HRESULT WINAPI IWineD3DSurfaceImpl_SaveS
     char *textureRow;
     IWineD3DSwapChain *swapChain = NULL;
     int width, height;
-    GLuint tmpTexture;
+    GLuint tmpTexture = 0;
     DWORD color;
     /*FIXME:
     Textures my not be stored in ->allocatedgMemory and a GlTexture
-- 
1.2.4



More information about the wine-patches mailing list