msi: Don't ignore failure to remove an existing product.
Hans Leidekker
hans at codeweavers.com
Mon Feb 18 02:20:20 CST 2013
---
dlls/msi/action.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/dlls/msi/action.c b/dlls/msi/action.c
index d48ecdd..14ca4d0 100644
--- a/dlls/msi/action.c
+++ b/dlls/msi/action.c
@@ -7261,7 +7261,7 @@ static UINT ITERATE_RemoveExistingProducts( MSIRECORD *rec, LPVOID param )
MSIPACKAGE *package = param;
const WCHAR *property = MSI_RecordGetString( rec, 7 );
int attrs = MSI_RecordGetInteger( rec, 5 );
- UINT len = sizeof(fmtW)/sizeof(fmtW[0]);
+ UINT exit_code, len = sizeof(fmtW)/sizeof(fmtW[0]);
WCHAR *product, *features, *cmd;
STARTUPINFOW si;
PROCESS_INFORMATION info;
@@ -7295,7 +7295,10 @@ static UINT ITERATE_RemoveExistingProducts( MSIRECORD *rec, LPVOID param )
CloseHandle( info.hThread );
WaitForSingleObject( info.hProcess, INFINITE );
+ GetExitCodeProcess( info.hProcess, &exit_code );
CloseHandle( info.hProcess );
+
+ if (exit_code && !(attrs & msidbUpgradeAttributesIgnoreRemoveFailure)) return exit_code;
return ERROR_SUCCESS;
}
--
1.7.10.4
More information about the wine-patches
mailing list