summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2018-11-28 18:34:45 (GMT)
committerBrad King <brad.king@kitware.com>2018-11-28 19:27:32 (GMT)
commit7954ba9bc196b34ced6c3359c464afbd0678c2e0 (patch)
treeb8ae4b33a92fcc84a8e7987760c21c3eec2258b3
parent652210e901f5e1e9bf8e25d35423348de8e50c1a (diff)
downloadCMake-7954ba9bc196b34ced6c3359c464afbd0678c2e0.zip
CMake-7954ba9bc196b34ced6c3359c464afbd0678c2e0.tar.gz
CMake-7954ba9bc196b34ced6c3359c464afbd0678c2e0.tar.bz2
productbuild: escape pkg-ref urls
Inspired-by: James Goruk <james.goruk@gmail.com> Fixes: #18645
-rw-r--r--Source/CPack/cmCPackPKGGenerator.cxx3
1 files changed, 2 insertions, 1 deletions
diff --git a/Source/CPack/cmCPackPKGGenerator.cxx b/Source/CPack/cmCPackPKGGenerator.cxx
index bdda386..9401bca 100644
--- a/Source/CPack/cmCPackPKGGenerator.cxx
+++ b/Source/CPack/cmCPackPKGGenerator.cxx
@@ -225,7 +225,8 @@ void cmCPackPKGGenerator::CreateChoice(const cmCPackComponent& component,
xout.Content(this->GetPackageName(component));
} else {
xout.Content("file:./");
- xout.Content(relativePackageLocation);
+ xout.Content(cmSystemTools::EncodeURL(relativePackageLocation,
+ /*escapeSlashes=*/false));
}
xout.EndElement(); // pkg-ref
}