[3/6] wined3d: Avoid XFree on NULL in CheckDeviceType.

Jan Zerebecki jan.wine at zerebecki.de
Thu Nov 23 12:58:13 CST 2006


If this patch is rejected from inclusion, please tell me why, as
I would have to ask anyway.

From: Jan Zerebecki <jan.wine at zerebecki.de>
Changelog:
wined3d: Avoid XFree on NULL in CheckDeviceType.
---

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

diff --git a/dlls/wined3d/directx.c b/dlls/wined3d/directx.c
index 6fa7a1b..778f6f7 100644
--- a/dlls/wined3d/directx.c
+++ b/dlls/wined3d/directx.c
@@ -1595,7 +1595,7 @@ static HRESULT WINAPI IWineD3DImpl_Check
               break ;
           }
       }
-      XFree(cfgs);
+      if(cfgs) XFree(cfgs);
       WineD3D_ReleaseFakeGLContext(ctx);
     }
 



More information about the wine-patches mailing list