summaryrefslogtreecommitdiffstats
path: root/Source/cmCoreTryCompile.cxx
diff options
context:
space:
mode:
authorDaniel Pfeifer <daniel@pfeifer-mail.de>2016-10-30 17:34:06 (GMT)
committerDaniel Pfeifer <daniel@pfeifer-mail.de>2016-10-30 17:34:06 (GMT)
commit602b78aa79f6d99e775fa0a84fb441156d192833 (patch)
tree41e41ce60fd8eefb7e34db35884bfa9925d73c8b /Source/cmCoreTryCompile.cxx
parentc58c739da7287a1cb33558f4e121ecdb23cfadd9 (diff)
downloadCMake-602b78aa79f6d99e775fa0a84fb441156d192833.zip
CMake-602b78aa79f6d99e775fa0a84fb441156d192833.tar.gz
CMake-602b78aa79f6d99e775fa0a84fb441156d192833.tar.bz2
Remove redundant c_str() calls
Diffstat (limited to 'Source/cmCoreTryCompile.cxx')
-rw-r--r--Source/cmCoreTryCompile.cxx10
1 files changed, 5 insertions, 5 deletions
diff --git a/Source/cmCoreTryCompile.cxx b/Source/cmCoreTryCompile.cxx
index a1de074..b7d2196 100644
--- a/Source/cmCoreTryCompile.cxx
+++ b/Source/cmCoreTryCompile.cxx
@@ -40,7 +40,7 @@ static std::string const kCMAKE_TRY_COMPILE_PLATFORM_VARIABLES =
int cmCoreTryCompile::TryCompileCode(std::vector<std::string> const& argv,
bool isTryRun)
{
- this->BinaryDirectory = argv[1].c_str();
+ this->BinaryDirectory = argv[1];
this->OutputFile = "";
// which signature were we called with ?
this->SrcFileSignature = true;
@@ -149,13 +149,13 @@ int cmCoreTryCompile::TryCompileCode(std::vector<std::string> const& argv,
}
}
} else if (doing == DoingOutputVariable) {
- outputVariable = argv[i].c_str();
+ outputVariable = argv[i];
doing = DoingNone;
} else if (doing == DoingCopyFile) {
- copyFile = argv[i].c_str();
+ copyFile = argv[i];
doing = DoingNone;
} else if (doing == DoingCopyFileError) {
- copyFileError = argv[i].c_str();
+ copyFileError = argv[i];
doing = DoingNone;
} else if (doing == DoingSources) {
sources.push_back(argv[i]);
@@ -163,7 +163,7 @@ int cmCoreTryCompile::TryCompileCode(std::vector<std::string> const& argv,
this->SrcFileSignature = false;
projectName = argv[i].c_str();
} else if (i == 4 && !this->SrcFileSignature) {
- targetName = argv[i].c_str();
+ targetName = argv[i];
} else {
std::ostringstream m;
m << "try_compile given unknown argument \"" << argv[i] << "\".";