diff options
author | Andrey Mishchenko <mishchea@gmail.com> | 2016-01-02 21:11:00 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2016-01-07 20:24:42 (GMT) |
commit | bbb3c4ffc18dcadc774b7fe4b2ceca1557ddb253 (patch) | |
tree | 1799fb39d020b69029bea90afbdcff175159d637 /Source/CPack/cmCPackDragNDropGenerator.h | |
parent | 5112da5c2fe9cfa35d741cd0f35d20c787797475 (diff) | |
download | CMake-bbb3c4ffc18dcadc774b7fe4b2ceca1557ddb253.zip CMake-bbb3c4ffc18dcadc774b7fe4b2ceca1557ddb253.tar.gz CMake-bbb3c4ffc18dcadc774b7fe4b2ceca1557ddb253.tar.bz2 |
CPack/DragNDrop: Fix handling of certain license file content (#15899)
There were issues in the special-character-escaping and line-wrapping
code which caused DragNDrop packaging to fail mysteriously at a later
step with parsing errors in the `sla.r` file generated by the following
code.
Diffstat (limited to 'Source/CPack/cmCPackDragNDropGenerator.h')
-rw-r--r-- | Source/CPack/cmCPackDragNDropGenerator.h | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/Source/CPack/cmCPackDragNDropGenerator.h b/Source/CPack/cmCPackDragNDropGenerator.h index b5e5ffe..604cdf5 100644 --- a/Source/CPack/cmCPackDragNDropGenerator.h +++ b/Source/CPack/cmCPackDragNDropGenerator.h @@ -50,11 +50,13 @@ private: std::string slaDirectory; bool singleLicense; - void WriteLicense(cmGeneratedFileStream& outputStream, int licenseNumber, - std::string licenseLanguage, std::string licenseFile = ""); - void BreakLongLine(const std::string& line, - std::vector<std::string>& lines); - void EscapeQuotes(std::string& line); + bool WriteLicense(cmGeneratedFileStream& outputStream, int licenseNumber, + std::string licenseLanguage, std::string licenseFile, + std::string *error); + bool BreakLongLine(const std::string& line, + std::vector<std::string>& lines, + std::string *error); + void EscapeQuotesAndBackslashes(std::string& line); }; #endif |