diff options
author | Sean Hall <r.sean.hall@gmail.com> | 2020-05-21 14:13:16 +1000 |
---|---|---|
committer | Sean Hall <r.sean.hall@gmail.com> | 2020-05-21 14:18:40 +1000 |
commit | 513286d4798572cc82a78554ef15ef2fe79f407e (patch) | |
tree | 3960b579a914c843f56c9045c59d194162d0a9d2 /src/engine/mspengine.cpp | |
parent | c903a96bd8d61a375448e1a6ad7b40bab8cb24c4 (diff) | |
download | wix-513286d4798572cc82a78554ef15ef2fe79f407e.tar.gz wix-513286d4798572cc82a78554ef15ef2fe79f407e.tar.bz2 wix-513286d4798572cc82a78554ef15ef2fe79f407e.zip |
WIXBUG:5980 Fix bugs around INSTALLUILEVEL_SOURCERESONLY.
Apply requires a valid hWnd since otherwise a source resolution prompt could hang the bundle.
Burn now defaults to INSTALLUILEVEL_NONE by itself if the bundle is not showing UI.
Diffstat (limited to 'src/engine/mspengine.cpp')
-rw-r--r-- | src/engine/mspengine.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/engine/mspengine.cpp b/src/engine/mspengine.cpp index 0dddb366..57321d75 100644 --- a/src/engine/mspengine.cpp +++ b/src/engine/mspengine.cpp | |||
@@ -44,6 +44,7 @@ static void DeterminePatchChainedTarget( | |||
44 | __out BOOL* pfSlipstreamed | 44 | __out BOOL* pfSlipstreamed |
45 | ); | 45 | ); |
46 | static HRESULT PlanTargetProduct( | 46 | static HRESULT PlanTargetProduct( |
47 | __in BOOTSTRAPPER_DISPLAY display, | ||
47 | __in BURN_USER_EXPERIENCE* pUserExperience, | 48 | __in BURN_USER_EXPERIENCE* pUserExperience, |
48 | __in BOOL fRollback, | 49 | __in BOOL fRollback, |
49 | __in BURN_PLAN* pPlan, | 50 | __in BURN_PLAN* pPlan, |
@@ -396,6 +397,7 @@ LExit: | |||
396 | // PlanAdd - adds the calculated execute and rollback actions for the package. | 397 | // PlanAdd - adds the calculated execute and rollback actions for the package. |
397 | // | 398 | // |
398 | extern "C" HRESULT MspEnginePlanAddPackage( | 399 | extern "C" HRESULT MspEnginePlanAddPackage( |
400 | __in BOOTSTRAPPER_DISPLAY display, | ||
399 | __in BURN_USER_EXPERIENCE* pUserExperience, | 401 | __in BURN_USER_EXPERIENCE* pUserExperience, |
400 | __in BURN_PACKAGE* pPackage, | 402 | __in BURN_PACKAGE* pPackage, |
401 | __in BURN_PLAN* pPlan, | 403 | __in BURN_PLAN* pPlan, |
@@ -433,13 +435,13 @@ extern "C" HRESULT MspEnginePlanAddPackage( | |||
433 | 435 | ||
434 | if (BOOTSTRAPPER_ACTION_STATE_NONE != pTargetProduct->execute) | 436 | if (BOOTSTRAPPER_ACTION_STATE_NONE != pTargetProduct->execute) |
435 | { | 437 | { |
436 | hr = PlanTargetProduct(pUserExperience, FALSE, pPlan, pLog, pVariables, pTargetProduct->execute, pPackage, pTargetProduct, hCacheEvent); | 438 | hr = PlanTargetProduct(display, pUserExperience, FALSE, pPlan, pLog, pVariables, pTargetProduct->execute, pPackage, pTargetProduct, hCacheEvent); |
437 | ExitOnFailure(hr, "Failed to plan target product."); | 439 | ExitOnFailure(hr, "Failed to plan target product."); |
438 | } | 440 | } |
439 | 441 | ||
440 | if (BOOTSTRAPPER_ACTION_STATE_NONE != pTargetProduct->rollback) | 442 | if (BOOTSTRAPPER_ACTION_STATE_NONE != pTargetProduct->rollback) |
441 | { | 443 | { |
442 | hr = PlanTargetProduct(pUserExperience, TRUE, pPlan, pLog, pVariables, pTargetProduct->rollback, pPackage, pTargetProduct, hCacheEvent); | 444 | hr = PlanTargetProduct(display, pUserExperience, TRUE, pPlan, pLog, pVariables, pTargetProduct->rollback, pPackage, pTargetProduct, hCacheEvent); |
443 | ExitOnFailure(hr, "Failed to plan rollack target product."); | 445 | ExitOnFailure(hr, "Failed to plan rollack target product."); |
444 | } | 446 | } |
445 | } | 447 | } |
@@ -877,6 +879,7 @@ static void DeterminePatchChainedTarget( | |||
877 | } | 879 | } |
878 | 880 | ||
879 | static HRESULT PlanTargetProduct( | 881 | static HRESULT PlanTargetProduct( |
882 | __in BOOTSTRAPPER_DISPLAY display, | ||
880 | __in BURN_USER_EXPERIENCE* pUserExperience, | 883 | __in BURN_USER_EXPERIENCE* pUserExperience, |
881 | __in BOOL fRollback, | 884 | __in BOOL fRollback, |
882 | __in BURN_PLAN* pPlan, | 885 | __in BURN_PLAN* pPlan, |
@@ -934,7 +937,7 @@ static HRESULT PlanTargetProduct( | |||
934 | hr = StrAllocString(&pAction->mspTarget.sczTargetProductCode, pTargetProduct->wzTargetProductCode, 0); | 937 | hr = StrAllocString(&pAction->mspTarget.sczTargetProductCode, pTargetProduct->wzTargetProductCode, 0); |
935 | ExitOnFailure(hr, "Failed to copy target product code."); | 938 | ExitOnFailure(hr, "Failed to copy target product code."); |
936 | 939 | ||
937 | hr = MsiEngineCalculateInstallUiLevel(pUserExperience, pPackage->sczId, !fRollback, pAction->mspTarget.action, | 940 | hr = MsiEngineCalculateInstallUiLevel(display, pUserExperience, pPackage->sczId, !fRollback, pAction->mspTarget.action, |
938 | &pAction->mspTarget.actionMsiProperty, &pAction->mspTarget.uiLevel, &pAction->mspTarget.fDisableExternalUiHandler); | 941 | &pAction->mspTarget.actionMsiProperty, &pAction->mspTarget.uiLevel, &pAction->mspTarget.fDisableExternalUiHandler); |
939 | ExitOnFailure(hr, "Failed to get msp ui options."); | 942 | ExitOnFailure(hr, "Failed to get msp ui options."); |
940 | 943 | ||