Hans Leidekker : cabinet: Fix a memory leak.

Alexandre Julliard julliard at winehq.org
Mon Jul 21 08:51:22 CDT 2008


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

Author: Hans Leidekker <hans at meelstraat.net>
Date:   Sat Jul 19 19:54:10 2008 +0200

cabinet: Fix a memory leak.

---

 dlls/cabinet/cabinet_main.c |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)

diff --git a/dlls/cabinet/cabinet_main.c b/dlls/cabinet/cabinet_main.c
index 7ebe63c..35810e3 100644
--- a/dlls/cabinet/cabinet_main.c
+++ b/dlls/cabinet/cabinet_main.c
@@ -338,7 +338,10 @@ HRESULT WINAPI Extract(SESSION *dest, LPCSTR szCabName)
         return E_FAIL;
 
     if (GetFileAttributesA(dest->Destination) == INVALID_FILE_ATTRIBUTES)
-        return S_OK;
+    {
+        res = S_OK;
+        goto end;
+    }
 
     /* split the cabinet name into path + name */
     str = HeapAlloc(GetProcessHeap(), 0, lstrlenA(szCabName)+1);




More information about the wine-cvs mailing list