summaryrefslogtreecommitdiffstats
path: root/Source/CPack
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2016-05-20 13:15:52 (GMT)
committerCMake Topic Stage <kwrobot@kitware.com>2016-05-20 13:15:52 (GMT)
commitacd039ae0e432d85c1317bd910d409e0300e280a (patch)
treecb59aff9a5e1c2a37f31c6ce491947ee3a961e13 /Source/CPack
parent4dc11643878bbc6562b94838dbfcbe9059e147c3 (diff)
parent40bee43a58f69848c1492f6fc53aecef363be95c (diff)
downloadCMake-acd039ae0e432d85c1317bd910d409e0300e280a.zip
CMake-acd039ae0e432d85c1317bd910d409e0300e280a.tar.gz
CMake-acd039ae0e432d85c1317bd910d409e0300e280a.tar.bz2
Merge topic 'minor-cleanup'
40bee43a cmCPackDragNDropGenerator: Replace std::{ostringstream => string}
Diffstat (limited to 'Source/CPack')
-rw-r--r--Source/CPack/cmCPackDragNDropGenerator.cxx9
1 files changed, 4 insertions, 5 deletions
diff --git a/Source/CPack/cmCPackDragNDropGenerator.cxx b/Source/CPack/cmCPackDragNDropGenerator.cxx
index e401657..9576eff 100644
--- a/Source/CPack/cmCPackDragNDropGenerator.cxx
+++ b/Source/CPack/cmCPackDragNDropGenerator.cxx
@@ -447,12 +447,11 @@ int cmCPackDragNDropGenerator::CreateDMG(const std::string& src_dir,
cmsys::RegularExpression mountpoint_regex(".*(/Volumes/[^\n]+)\n.*");
mountpoint_regex.find(attach_output.c_str());
- std::ostringstream temp_mount;
- temp_mount << mountpoint_regex.match(1);
+ std::string const temp_mount = mountpoint_regex.match(1);
// Remove dummy padding file so we have enough space on RW image ...
std::ostringstream dummy_padding;
- dummy_padding << temp_mount.str() << "/.dummy-padding-file";
+ dummy_padding << temp_mount << "/.dummy-padding-file";
if (!cmSystemTools::RemoveFile(dummy_padding.str())) {
cmCPackLogger(cmCPackLog::LOG_ERROR, "Error removing dummy padding file."
<< std::endl);
@@ -465,7 +464,7 @@ int cmCPackDragNDropGenerator::CreateDMG(const std::string& src_dir,
std::ostringstream setfile_command;
setfile_command << this->GetOption("CPACK_COMMAND_SETFILE");
setfile_command << " -a C";
- setfile_command << " \"" << temp_mount.str() << "\"";
+ setfile_command << " \"" << temp_mount << "\"";
if (!this->RunCommand(setfile_command)) {
cmCPackLogger(cmCPackLog::LOG_ERROR,
@@ -497,7 +496,7 @@ int cmCPackDragNDropGenerator::CreateDMG(const std::string& src_dir,
std::ostringstream detach_command;
detach_command << this->GetOption("CPACK_COMMAND_HDIUTIL");
detach_command << " detach";
- detach_command << " \"" << temp_mount.str() << "\"";
+ detach_command << " \"" << temp_mount << "\"";
if (!this->RunCommand(detach_command)) {
cmCPackLogger(cmCPackLog::LOG_ERROR,