James Hawkins : msi: Free the current filename if we choose to not extract the file.

Alexandre Julliard julliard at winehq.org
Fri Dec 18 10:49:09 CST 2009


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

Author: James Hawkins <truiken at gmail.com>
Date:   Thu Dec 17 20:00:45 2009 -0800

msi: Free the current filename if we choose to not extract the file.

---

 dlls/msi/media.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)

diff --git a/dlls/msi/media.c b/dlls/msi/media.c
index 67d73cc..0a6c431 100644
--- a/dlls/msi/media.c
+++ b/dlls/msi/media.c
@@ -334,7 +334,12 @@ static INT_PTR cabinet_copy_file(FDINOTIFICATIONTYPE fdint,
     data->curfile = strdupAtoW(pfdin->psz1);
     if (!data->cb(data->package, data->curfile, MSICABEXTRACT_BEGINEXTRACT, &path,
                   &attrs, data->user))
+    {
+        /* We're not extracting this file, so free the filename. */
+        msi_free(data->curfile);
+        data->curfile = NULL;
         goto done;
+    }
 
     TRACE("extracting %s\n", debugstr_w(path));
 




More information about the wine-cvs mailing list