aboutsummaryrefslogtreecommitdiff
path: root/src/engine
diff options
context:
space:
mode:
authorSean Hall <r.sean.hall@gmail.com>2020-11-01 17:08:51 -0600
committerSean Hall <r.sean.hall@gmail.com>2020-11-01 18:35:01 -0600
commitd70b0710ba8ae05a5018ce96967f1cf7a7f717f5 (patch)
tree95f6d0fadaa7ab93e0c3265fd4c766d89f0dc080 /src/engine
parent352aefb0ac67ffbf74cd126db710031d4944fe89 (diff)
downloadwix-d70b0710ba8ae05a5018ce96967f1cf7a7f717f5.tar.gz
wix-d70b0710ba8ae05a5018ce96967f1cf7a7f717f5.tar.bz2
wix-d70b0710ba8ae05a5018ce96967f1cf7a7f717f5.zip
WIXFEAT:5355 - Don't clear variable for missing key or value.
Diffstat (limited to 'src/engine')
-rw-r--r--src/engine/search.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/engine/search.cpp b/src/engine/search.cpp
index 065003c7..6d5f8d49 100644
--- a/src/engine/search.cpp
+++ b/src/engine/search.cpp
@@ -946,8 +946,7 @@ static HRESULT RegistrySearchValue(
946 { 946 {
947 // What if there is a hidden variable in sczKey? 947 // What if there is a hidden variable in sczKey?
948 LogStringLine(REPORT_STANDARD, "Registry key not found. Key = '%ls'", sczKey); 948 LogStringLine(REPORT_STANDARD, "Registry key not found. Key = '%ls'", sczKey);
949 hr = VariableSetVariant(pVariables, pSearch->sczVariable, &value); 949
950 ExitOnFailure(hr, "Failed to clear variable.");
951 ExitFunction1(hr = S_OK); 950 ExitFunction1(hr = S_OK);
952 } 951 }
953 ExitOnFailure(hr, "Failed to open registry key."); 952 ExitOnFailure(hr, "Failed to open registry key.");
@@ -958,8 +957,7 @@ static HRESULT RegistrySearchValue(
958 { 957 {
959 // What if there is a hidden variable in sczKey or sczValue? 958 // What if there is a hidden variable in sczKey or sczValue?
960 LogStringLine(REPORT_STANDARD, "Registry value not found. Key = '%ls', Value = '%ls'", sczKey, sczValue); 959 LogStringLine(REPORT_STANDARD, "Registry value not found. Key = '%ls', Value = '%ls'", sczKey, sczValue);
961 hr = VariableSetVariant(pVariables, pSearch->sczVariable, &value); 960
962 ExitOnFailure(hr, "Failed to clear variable.");
963 ExitFunction1(hr = S_OK); 961 ExitFunction1(hr = S_OK);
964 } 962 }
965 ExitOnWin32Error(er, hr, "Failed to query registry key value size."); 963 ExitOnWin32Error(er, hr, "Failed to query registry key value size.");