aboutsummaryrefslogtreecommitdiff
path: root/src/wixstdba/WixStandardBootstrapperApplication.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/wixstdba/WixStandardBootstrapperApplication.cpp')
-rw-r--r--src/wixstdba/WixStandardBootstrapperApplication.cpp11
1 files changed, 8 insertions, 3 deletions
diff --git a/src/wixstdba/WixStandardBootstrapperApplication.cpp b/src/wixstdba/WixStandardBootstrapperApplication.cpp
index c5ef59ec..44c77057 100644
--- a/src/wixstdba/WixStandardBootstrapperApplication.cpp
+++ b/src/wixstdba/WixStandardBootstrapperApplication.cpp
@@ -264,7 +264,7 @@ public: // IBootstrapperApplication
264 __in BOOTSTRAPPER_RELATION_TYPE relationType, 264 __in BOOTSTRAPPER_RELATION_TYPE relationType,
265 __in LPCWSTR wzBundleTag, 265 __in LPCWSTR wzBundleTag,
266 __in BOOL fPerMachine, 266 __in BOOL fPerMachine,
267 __in DWORD64 dw64Version, 267 __in LPCWSTR wzVersion,
268 __in BOOTSTRAPPER_RELATED_OPERATION operation, 268 __in BOOTSTRAPPER_RELATED_OPERATION operation,
269 __inout BOOL* pfCancel 269 __inout BOOL* pfCancel
270 ) 270 )
@@ -281,7 +281,7 @@ public: // IBootstrapperApplication
281 m_fDowngrading = TRUE; 281 m_fDowngrading = TRUE;
282 } 282 }
283 283
284 return CBalBaseBootstrapperApplication::OnDetectRelatedBundle(wzBundleId, relationType, wzBundleTag, fPerMachine, dw64Version, operation, pfCancel); 284 return CBalBaseBootstrapperApplication::OnDetectRelatedBundle(wzBundleId, relationType, wzBundleTag, fPerMachine, wzVersion, operation, pfCancel);
285 } 285 }
286 286
287 287
@@ -2272,6 +2272,7 @@ private: // privates
2272 HRESULT hr = S_OK; 2272 HRESULT hr = S_OK;
2273 ULARGE_INTEGER uliVersion = { }; 2273 ULARGE_INTEGER uliVersion = { };
2274 LPWSTR sczCurrentPath = NULL; 2274 LPWSTR sczCurrentPath = NULL;
2275 VERUTIL_VERSION* pVersion = NULL;
2275 2276
2276 hr = PathForCurrentProcess(&sczCurrentPath, NULL); 2277 hr = PathForCurrentProcess(&sczCurrentPath, NULL);
2277 BalExitOnFailure(hr, "Failed to get bundle path."); 2278 BalExitOnFailure(hr, "Failed to get bundle path.");
@@ -2279,10 +2280,14 @@ private: // privates
2279 hr = FileVersion(sczCurrentPath, &uliVersion.HighPart, &uliVersion.LowPart); 2280 hr = FileVersion(sczCurrentPath, &uliVersion.HighPart, &uliVersion.LowPart);
2280 BalExitOnFailure(hr, "Failed to get bundle file version."); 2281 BalExitOnFailure(hr, "Failed to get bundle file version.");
2281 2282
2282 hr = m_pEngine->SetVariableVersion(WIXSTDBA_VARIABLE_BUNDLE_FILE_VERSION, uliVersion.QuadPart); 2283 hr = VerVersionFromQword(uliVersion.QuadPart, &pVersion);
2284 BalExitOnFailure(hr, "Failed to create bundle file version.");
2285
2286 hr = m_pEngine->SetVariableVersion(WIXSTDBA_VARIABLE_BUNDLE_FILE_VERSION, pVersion->sczVersion);
2283 BalExitOnFailure(hr, "Failed to set WixBundleFileVersion variable."); 2287 BalExitOnFailure(hr, "Failed to set WixBundleFileVersion variable.");
2284 2288
2285 LExit: 2289 LExit:
2290 ReleaseVerutilVersion(pVersion);
2286 ReleaseStr(sczCurrentPath); 2291 ReleaseStr(sczCurrentPath);
2287 2292
2288 return hr; 2293 return hr;