diff options
author | Sean Hall <r.sean.hall@gmail.com> | 2022-06-03 17:48:39 -0500 |
---|---|---|
committer | Sean Hall <r.sean.hall@gmail.com> | 2022-06-07 19:44:36 -0500 |
commit | 6b0f2d978504da82070523eb6adb0b59f9812e93 (patch) | |
tree | 6f0b258519a0f51bf589e4313206b3ffeaa32a41 /src/burn | |
parent | b652e93a460b4b822a01382e5992f96f1d805ffe (diff) | |
download | wix-6b0f2d978504da82070523eb6adb0b59f9812e93.tar.gz wix-6b0f2d978504da82070523eb6adb0b59f9812e93.tar.bz2 wix-6b0f2d978504da82070523eb6adb0b59f9812e93.zip |
Add PathSkipPastRoot.
Diffstat (limited to 'src/burn')
-rw-r--r-- | src/burn/engine/bundlepackageengine.cpp | 2 | ||||
-rw-r--r-- | src/burn/engine/exeengine.cpp | 2 | ||||
-rw-r--r-- | src/burn/engine/logging.cpp | 6 |
3 files changed, 6 insertions, 4 deletions
diff --git a/src/burn/engine/bundlepackageengine.cpp b/src/burn/engine/bundlepackageengine.cpp index 97861436..8ba8e0d2 100644 --- a/src/burn/engine/bundlepackageengine.cpp +++ b/src/burn/engine/bundlepackageengine.cpp | |||
@@ -763,7 +763,7 @@ static HRESULT ExecuteBundle( | |||
763 | 763 | ||
764 | if (fPseudoPackage) | 764 | if (fPseudoPackage) |
765 | { | 765 | { |
766 | if (!PathIsFullyQualified(pPackagePayload->sczFilePath, NULL)) | 766 | if (!PathIsFullyQualified(pPackagePayload->sczFilePath)) |
767 | { | 767 | { |
768 | ExitWithRootFailure(hr, E_INVALIDSTATE, "Related bundles must have a fully qualified target path."); | 768 | ExitWithRootFailure(hr, E_INVALIDSTATE, "Related bundles must have a fully qualified target path."); |
769 | } | 769 | } |
diff --git a/src/burn/engine/exeengine.cpp b/src/burn/engine/exeengine.cpp index c3757e92..fb852c78 100644 --- a/src/burn/engine/exeengine.cpp +++ b/src/burn/engine/exeengine.cpp | |||
@@ -363,7 +363,7 @@ extern "C" HRESULT ExeEngineExecutePackage( | |||
363 | 363 | ||
364 | if (pPackage->Exe.fPseudoPackage && BURN_PAYLOAD_VERIFICATION_UPDATE_BUNDLE != pPackagePayload->verification) | 364 | if (pPackage->Exe.fPseudoPackage && BURN_PAYLOAD_VERIFICATION_UPDATE_BUNDLE != pPackagePayload->verification) |
365 | { | 365 | { |
366 | if (!PathIsFullyQualified(pPackagePayload->sczFilePath, NULL)) | 366 | if (!PathIsFullyQualified(pPackagePayload->sczFilePath)) |
367 | { | 367 | { |
368 | ExitWithRootFailure(hr, E_INVALIDSTATE, "Pseudo ExePackages must have a fully qualified target path."); | 368 | ExitWithRootFailure(hr, E_INVALIDSTATE, "Pseudo ExePackages must have a fully qualified target path."); |
369 | } | 369 | } |
diff --git a/src/burn/engine/logging.cpp b/src/burn/engine/logging.cpp index 3a403025..77f5079c 100644 --- a/src/burn/engine/logging.cpp +++ b/src/burn/engine/logging.cpp | |||
@@ -134,10 +134,12 @@ extern "C" HRESULT LoggingOpen( | |||
134 | 134 | ||
135 | if (sczPrefixFormatted && *sczPrefixFormatted) | 135 | if (sczPrefixFormatted && *sczPrefixFormatted) |
136 | { | 136 | { |
137 | // Best effort to open default logging. | ||
137 | LPCWSTR wzPrefix = sczPrefixFormatted; | 138 | LPCWSTR wzPrefix = sczPrefixFormatted; |
139 | LPCWSTR wzPastRoot = PathSkipPastRoot(sczPrefixFormatted, NULL, NULL, NULL); | ||
138 | 140 | ||
139 | // Best effort to open default logging. | 141 | // If the log path is rooted and has a file component, then use that path as is. |
140 | if (PathIsRooted(sczPrefixFormatted)) | 142 | if (wzPastRoot && *wzPastRoot) |
141 | { | 143 | { |
142 | hr = PathGetDirectory(sczPrefixFormatted, &sczLoggingBaseFolder); | 144 | hr = PathGetDirectory(sczPrefixFormatted, &sczLoggingBaseFolder); |
143 | ExitOnFailure(hr, "Failed to get parent directory from '%ls'.", sczPrefixFormatted); | 145 | ExitOnFailure(hr, "Failed to get parent directory from '%ls'.", sczPrefixFormatted); |