diff options
author | Sean Hall <r.sean.hall@gmail.com> | 2020-10-31 21:22:52 -0600 |
---|---|---|
committer | Sean Hall <r.sean.hall@gmail.com> | 2020-10-31 22:26:15 -0500 |
commit | fac8fc35113cd9c42dc9cc4ea62d2645db863760 (patch) | |
tree | e31b2c47ab5c5c81dc55b46efd9f6676378cc51e | |
parent | a0c40d5a1b8537a6338dacc27a88d236077ab785 (diff) | |
download | wix-fac8fc35113cd9c42dc9cc4ea62d2645db863760.tar.gz wix-fac8fc35113cd9c42dc9cc4ea62d2645db863760.tar.bz2 wix-fac8fc35113cd9c42dc9cc4ea62d2645db863760.zip |
Default to same-version upgrades for bundles.
-rw-r--r-- | src/engine/detect.cpp | 8 | ||||
-rw-r--r-- | src/engine/plan.cpp | 2 |
2 files changed, 5 insertions, 5 deletions
diff --git a/src/engine/detect.cpp b/src/engine/detect.cpp index 9e4681bb..176780af 100644 --- a/src/engine/detect.cpp +++ b/src/engine/detect.cpp | |||
@@ -175,13 +175,13 @@ extern "C" HRESULT DetectReportRelatedBundles( | |||
175 | hr = VerCompareParsedVersions(pRegistration->pVersion, pRelatedBundle->pVersion, &nCompareResult); | 175 | hr = VerCompareParsedVersions(pRegistration->pVersion, pRelatedBundle->pVersion, &nCompareResult); |
176 | ExitOnFailure(hr, "Failed to compare bundle version '%ls' to related bundle version '%ls'", pRegistration->pVersion, pRelatedBundle->pVersion); | 176 | ExitOnFailure(hr, "Failed to compare bundle version '%ls' to related bundle version '%ls'", pRegistration->pVersion, pRelatedBundle->pVersion); |
177 | 177 | ||
178 | if (nCompareResult > 0) | 178 | if (nCompareResult < 0) |
179 | { | 179 | { |
180 | operation = BOOTSTRAPPER_RELATED_OPERATION_MAJOR_UPGRADE; | 180 | operation = BOOTSTRAPPER_RELATED_OPERATION_DOWNGRADE; |
181 | } | 181 | } |
182 | else if (nCompareResult < 0) | 182 | else |
183 | { | 183 | { |
184 | operation = BOOTSTRAPPER_RELATED_OPERATION_DOWNGRADE; | 184 | operation = BOOTSTRAPPER_RELATED_OPERATION_MAJOR_UPGRADE; |
185 | } | 185 | } |
186 | } | 186 | } |
187 | break; | 187 | break; |
diff --git a/src/engine/plan.cpp b/src/engine/plan.cpp index f6b681b6..3c0e1c50 100644 --- a/src/engine/plan.cpp +++ b/src/engine/plan.cpp | |||
@@ -1265,7 +1265,7 @@ extern "C" HRESULT PlanRelatedBundlesBegin( | |||
1265 | hr = VerCompareParsedVersions(pRegistration->pVersion, pRelatedBundle->pVersion, &nCompareResult); | 1265 | hr = VerCompareParsedVersions(pRegistration->pVersion, pRelatedBundle->pVersion, &nCompareResult); |
1266 | ExitOnFailure(hr, "Failed to compare bundle version '%ls' to related bundle version '%ls'", pRegistration->pVersion, pRelatedBundle->pVersion); | 1266 | ExitOnFailure(hr, "Failed to compare bundle version '%ls' to related bundle version '%ls'", pRegistration->pVersion, pRelatedBundle->pVersion); |
1267 | 1267 | ||
1268 | pRelatedBundle->package.requested = (nCompareResult > 0) ? BOOTSTRAPPER_REQUEST_STATE_ABSENT : BOOTSTRAPPER_REQUEST_STATE_NONE; | 1268 | pRelatedBundle->package.requested = (nCompareResult < 0) ? BOOTSTRAPPER_REQUEST_STATE_NONE : BOOTSTRAPPER_REQUEST_STATE_ABSENT; |
1269 | } | 1269 | } |
1270 | break; | 1270 | break; |
1271 | case BOOTSTRAPPER_RELATION_PATCH: __fallthrough; | 1271 | case BOOTSTRAPPER_RELATION_PATCH: __fallthrough; |