Marcus Meissner : wbemprox: Fixed leaking dirstack (Coverity).

Alexandre Julliard julliard at winehq.org
Fri Jun 21 11:28:10 CDT 2013


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

Author: Marcus Meissner <marcus at jet.franken.de>
Date:   Thu Jun 20 22:44:00 2013 +0200

wbemprox: Fixed leaking dirstack (Coverity).

---

 dlls/wbemprox/builtin.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/dlls/wbemprox/builtin.c b/dlls/wbemprox/builtin.c
index 3cf47f8..9e2369a 100644
--- a/dlls/wbemprox/builtin.c
+++ b/dlls/wbemprox/builtin.c
@@ -1273,11 +1273,13 @@ static enum fill_status fill_directory( struct table *table, const struct expr *
     DWORD drives = GetLogicalDrives();
     WIN32_FIND_DATAW data;
     HANDLE handle;
-    struct dirstack *dirstack = alloc_dirstack(2);
+    struct dirstack *dirstack;
     enum fill_status status = FILL_STATUS_UNFILTERED;
 
     if (!resize_table( table, 4, sizeof(*rec) )) return FILL_STATUS_FAILED;
 
+    dirstack = alloc_dirstack(2);
+
     for (i = 0; i < sizeof(drives); i++)
     {
         if (!(drives & (1 << i))) continue;




More information about the wine-cvs mailing list