diff options
author | Daniel Pfeifer <daniel@pfeifer-mail.de> | 2016-06-14 20:37:36 (GMT) |
---|---|---|
committer | Daniel Pfeifer <daniel@pfeifer-mail.de> | 2016-06-14 20:37:36 (GMT) |
commit | 24ab29b882548d9eceeb20d3ecbc5b9cc918bb7c (patch) | |
tree | 8b14c406c768e3fe8a934e9ed9ba95a35b91cdaf /Source/cmCLocaleEnvironmentScope.cxx | |
parent | ab8b77dd33e9a13551af402b2cf7ee3aaa5486b8 (diff) | |
download | CMake-24ab29b882548d9eceeb20d3ecbc5b9cc918bb7c.zip CMake-24ab29b882548d9eceeb20d3ecbc5b9cc918bb7c.tar.gz CMake-24ab29b882548d9eceeb20d3ecbc5b9cc918bb7c.tar.bz2 |
Prefer istringstream and ostringstream over stringstream.
Use istringsream for parsing, ostringstream for generation.
Diffstat (limited to 'Source/cmCLocaleEnvironmentScope.cxx')
-rw-r--r-- | Source/cmCLocaleEnvironmentScope.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Source/cmCLocaleEnvironmentScope.cxx b/Source/cmCLocaleEnvironmentScope.cxx index ee9acde..a19dbae 100644 --- a/Source/cmCLocaleEnvironmentScope.cxx +++ b/Source/cmCLocaleEnvironmentScope.cxx @@ -45,7 +45,7 @@ void cmCLocaleEnvironmentScope::SetEnv(std::string const& key, if (value.empty()) { cmSystemTools::UnsetEnv(key.c_str()); } else { - std::stringstream tmp; + std::ostringstream tmp; tmp << key << "=" << value; cmSystemTools::PutEnv(tmp.str()); } @@ -55,7 +55,7 @@ cmCLocaleEnvironmentScope::~cmCLocaleEnvironmentScope() { for (backup_map_t::const_iterator i = this->EnvironmentBackup.begin(); i != this->EnvironmentBackup.end(); ++i) { - std::stringstream tmp; + std::ostringstream tmp; tmp << i->first << "=" << i->second; cmSystemTools::PutEnv(tmp.str()); } |