From 582f2640d2828da6d010d27715a30e13d0dc8adf Mon Sep 17 00:00:00 2001 From: Sebastian Lackner Date: Thu, 14 Aug 2014 01:39:13 +0200 Subject: [PATCH] msi: Fix ITERATE_MoveFiles when no source- and destname is specified. --- dlls/msi/files.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/dlls/msi/files.c b/dlls/msi/files.c index ec46ae3318f..62e5f43606f 100644 --- a/dlls/msi/files.c +++ b/dlls/msi/files.c @@ -843,7 +843,13 @@ static UINT ITERATE_MoveFiles( MSIRECORD *rec, LPVOID param ) { if (!wildcards) { - destname = strdupW(sourcename); + WCHAR *p; + if (sourcename) + destname = strdupW(sourcename); + else if ((p = strrchrW(sourcedir, '\\'))) + destname = strdupW(p + 1); + else + destname = strdupW(sourcedir); if (!destname) goto done; } -- 2.11.4.GIT