diff --git a/dlls/msi/install.c b/dlls/msi/install.c index 2098cb2fc14..7e9fdad3b9f 100644 --- a/dlls/msi/install.c +++ b/dlls/msi/install.c @@ -360,7 +360,10 @@ UINT MSI_SetTargetPathW(MSIPACKAGE *package, LPCWSTR szFolder, if (attrib == INVALID_FILE_ATTRIBUTES) { if (!CreateDirectoryW(szFolderPath,NULL)) + { + msi_free( path ); return ERROR_FUNCTION_FAILED; + } RemoveDirectoryW(szFolderPath); }