diff options
| author | Jacob Hoover <jacob.hoover@greenheck.com> | 2022-11-10 10:48:23 -0600 |
|---|---|---|
| committer | Sean Hall <r.sean.hall@gmail.com> | 2022-11-10 23:49:10 -0600 |
| commit | fa393914f12f6d6bc88a73e4d5b009da765f6dd5 (patch) | |
| tree | 6dbf354d4542b3e085795b0a917eaafc1eead415 /src/burn/engine/EngineForExtension.cpp | |
| parent | c843b47d6233153fa961c6d0e61edf7cedf255bb (diff) | |
| download | wix-fa393914f12f6d6bc88a73e4d5b009da765f6dd5.tar.gz wix-fa393914f12f6d6bc88a73e4d5b009da765f6dd5.tar.bz2 wix-fa393914f12f6d6bc88a73e4d5b009da765f6dd5.zip | |
WIXFEAT-3704 - Allow access to persisted variables from related bundles
Diffstat (limited to 'src/burn/engine/EngineForExtension.cpp')
| -rw-r--r-- | src/burn/engine/EngineForExtension.cpp | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/src/burn/engine/EngineForExtension.cpp b/src/burn/engine/EngineForExtension.cpp index 2e1c98fd..bb134a61 100644 --- a/src/burn/engine/EngineForExtension.cpp +++ b/src/burn/engine/EngineForExtension.cpp | |||
| @@ -203,6 +203,22 @@ LExit: | |||
| 203 | return hr; | 203 | return hr; |
| 204 | } | 204 | } |
| 205 | 205 | ||
| 206 | static HRESULT BEEngineGetRelatedBundleVariable( | ||
| 207 | __in BURN_EXTENSION_ENGINE_CONTEXT* pContext, | ||
| 208 | __in const LPVOID pvArgs, | ||
| 209 | __inout LPVOID pvResults | ||
| 210 | ) | ||
| 211 | { | ||
| 212 | HRESULT hr = S_OK; | ||
| 213 | ValidateMessageArgs(hr, pvArgs, BUNDLE_EXTENSION_ENGINE_GETRELATEDBUNDLEVARIABLE_ARGS, pArgs); | ||
| 214 | ValidateMessageResults(hr, pvResults, BUNDLE_EXTENSION_ENGINE_GETRELATEDBUNDLEVARIABLE_RESULTS, pResults); | ||
| 215 | |||
| 216 | hr = ExternalEngineGetRelatedBundleVariable(pContext->pEngineState, pArgs->wzBundleId, pArgs->wzVariable, pResults->wzValue, &pResults->cchValue); | ||
| 217 | |||
| 218 | LExit: | ||
| 219 | return hr; | ||
| 220 | } | ||
| 221 | |||
| 206 | HRESULT WINAPI EngineForExtensionProc( | 222 | HRESULT WINAPI EngineForExtensionProc( |
| 207 | __in BUNDLE_EXTENSION_ENGINE_MESSAGE message, | 223 | __in BUNDLE_EXTENSION_ENGINE_MESSAGE message, |
| 208 | __in const LPVOID pvArgs, | 224 | __in const LPVOID pvArgs, |
| @@ -253,6 +269,9 @@ HRESULT WINAPI EngineForExtensionProc( | |||
| 253 | case BUNDLE_EXTENSION_ENGINE_MESSAGE_COMPAREVERSIONS: | 269 | case BUNDLE_EXTENSION_ENGINE_MESSAGE_COMPAREVERSIONS: |
| 254 | hr = BEEngineCompareVersions(pContext, pvArgs, pvResults); | 270 | hr = BEEngineCompareVersions(pContext, pvArgs, pvResults); |
| 255 | break; | 271 | break; |
| 272 | case BUNDLE_EXTENSION_ENGINE_MESSAGE_GETRELATEDBUNDLEVARIABLE: | ||
| 273 | hr = BEEngineGetRelatedBundleVariable(pContext, pvArgs, pvResults); | ||
| 274 | break; | ||
| 256 | default: | 275 | default: |
| 257 | hr = E_NOTIMPL; | 276 | hr = E_NOTIMPL; |
| 258 | break; | 277 | break; |
