From 30c1b88828464e1220c7eb4b884aedce6913607f Mon Sep 17 00:00:00 2001 From: James Hawkins Date: Fri, 4 Apr 2008 22:48:20 -0500 Subject: [PATCH] msi: Reset the feature states if iInstallLevel is 0 or below. --- dlls/msi/install.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/dlls/msi/install.c b/dlls/msi/install.c index 999840dae05..64154592ef1 100644 --- a/dlls/msi/install.c +++ b/dlls/msi/install.c @@ -1169,15 +1169,16 @@ UINT MSI_SetInstallLevel( MSIPACKAGE *package, int iInstallLevel ) TRACE("%p %i\n", package, iInstallLevel); - if (iInstallLevel<1 || iInstallLevel>32767) + if (iInstallLevel > 32767) return ERROR_INVALID_PARAMETER; + if (iInstallLevel < 1) + return MSI_SetFeatureStates( package ); + sprintfW( level, fmt, iInstallLevel ); r = MSI_SetPropertyW( package, szInstallLevel, level ); if ( r == ERROR_SUCCESS ) - { r = MSI_SetFeatureStates( package ); - } return r; } -- 2.11.4.GIT