diff options
author | Sean Hall <r.sean.hall@gmail.com> | 2021-06-04 13:38:04 -0500 |
---|---|---|
committer | Sean Hall <r.sean.hall@gmail.com> | 2021-06-04 14:57:11 -0500 |
commit | 4fac8fca0e04b6d7f9be8c3cf90439f9f614cecf (patch) | |
tree | 966ca79322c925d55a797bf2f6c26eb0f4b9cd68 /src/ext/Bal/wixstdba/WixStandardBootstrapperApplication.cpp | |
parent | 1b2b372b452b5aee5dd2b8aa2cbbbe49e8d3c9e6 (diff) | |
download | wix-4fac8fca0e04b6d7f9be8c3cf90439f9f614cecf.tar.gz wix-4fac8fca0e04b6d7f9be8c3cf90439f9f614cecf.tar.bz2 wix-4fac8fca0e04b6d7f9be8c3cf90439f9f614cecf.zip |
Fix loading BAFunctions.
Diffstat (limited to 'src/ext/Bal/wixstdba/WixStandardBootstrapperApplication.cpp')
-rw-r--r-- | src/ext/Bal/wixstdba/WixStandardBootstrapperApplication.cpp | 23 |
1 files changed, 2 insertions, 21 deletions
diff --git a/src/ext/Bal/wixstdba/WixStandardBootstrapperApplication.cpp b/src/ext/Bal/wixstdba/WixStandardBootstrapperApplication.cpp index d4bf7b43..42dfb220 100644 --- a/src/ext/Bal/wixstdba/WixStandardBootstrapperApplication.cpp +++ b/src/ext/Bal/wixstdba/WixStandardBootstrapperApplication.cpp | |||
@@ -3849,9 +3849,6 @@ private: // privates | |||
3849 | { | 3849 | { |
3850 | HRESULT hr = S_OK; | 3850 | HRESULT hr = S_OK; |
3851 | IXMLDOMNode* pBAFunctionsNode = NULL; | 3851 | IXMLDOMNode* pBAFunctionsNode = NULL; |
3852 | IXMLDOMNode* pPayloadNode = NULL; | ||
3853 | LPWSTR sczPayloadId = NULL; | ||
3854 | LPWSTR sczPayloadXPath = NULL; | ||
3855 | LPWSTR sczBafName = NULL; | 3852 | LPWSTR sczBafName = NULL; |
3856 | LPWSTR sczBafPath = NULL; | 3853 | LPWSTR sczBafPath = NULL; |
3857 | BA_FUNCTIONS_CREATE_ARGS bafCreateArgs = { }; | 3854 | BA_FUNCTIONS_CREATE_ARGS bafCreateArgs = { }; |
@@ -3865,21 +3862,8 @@ private: // privates | |||
3865 | ExitFunction(); | 3862 | ExitFunction(); |
3866 | } | 3863 | } |
3867 | 3864 | ||
3868 | hr = XmlGetAttributeEx(pBAFunctionsNode, L"PayloadId", &sczPayloadId); | 3865 | hr = XmlGetAttributeEx(pBAFunctionsNode, L"FilePath", &sczBafName); |
3869 | BalExitOnFailure(hr, "Failed to get BAFunctions PayloadId."); | 3866 | BalExitOnFailure(hr, "Failed to get BAFunctions FilePath."); |
3870 | |||
3871 | hr = StrAllocFormatted(&sczPayloadXPath, L"/BootstrapperApplicationData/WixPayloadProperties[@Payload='%ls']", sczPayloadId); | ||
3872 | BalExitOnFailure(hr, "Failed to format BAFunctions payload XPath."); | ||
3873 | |||
3874 | hr = XmlSelectSingleNode(pixdManifest, sczPayloadXPath, &pPayloadNode); | ||
3875 | if (S_FALSE == hr) | ||
3876 | { | ||
3877 | hr = E_NOTFOUND; | ||
3878 | } | ||
3879 | BalExitOnFailure(hr, "Failed to find WixPayloadProperties node for BAFunctions PayloadId: %ls.", sczPayloadId); | ||
3880 | |||
3881 | hr = XmlGetAttributeEx(pPayloadNode, L"Name", &sczBafName); | ||
3882 | BalExitOnFailure(hr, "Failed to get BAFunctions Name."); | ||
3883 | 3867 | ||
3884 | hr = PathRelativeToModule(&sczBafPath, sczBafName, m_hModule); | 3868 | hr = PathRelativeToModule(&sczBafPath, sczBafName, m_hModule); |
3885 | BalExitOnFailure(hr, "Failed to get path to BAFunctions DLL."); | 3869 | BalExitOnFailure(hr, "Failed to get path to BAFunctions DLL."); |
@@ -3912,10 +3896,7 @@ private: // privates | |||
3912 | } | 3896 | } |
3913 | ReleaseStr(sczBafPath); | 3897 | ReleaseStr(sczBafPath); |
3914 | ReleaseStr(sczBafName); | 3898 | ReleaseStr(sczBafName); |
3915 | ReleaseStr(sczPayloadXPath); | ||
3916 | ReleaseStr(sczPayloadId); | ||
3917 | ReleaseObject(pBAFunctionsNode); | 3899 | ReleaseObject(pBAFunctionsNode); |
3918 | ReleaseObject(pPayloadNode); | ||
3919 | 3900 | ||
3920 | return hr; | 3901 | return hr; |
3921 | } | 3902 | } |