diff options
Diffstat (limited to 'Source/cmState.cxx')
-rw-r--r-- | Source/cmState.cxx | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Source/cmState.cxx b/Source/cmState.cxx index b674b4e..09b11b2 100644 --- a/Source/cmState.cxx +++ b/Source/cmState.cxx @@ -965,7 +965,7 @@ void cmState::Directory::SetCurrentSource(std::string const& dir) loc, this->DirectoryState->CurrentSourceDirectoryComponents); this->ComputeRelativePathTopSource(); - this->Snapshot_.SetDefinition("CMAKE_CURRENT_SOURCE_DIR", loc.c_str()); + this->Snapshot_.SetDefinition("CMAKE_CURRENT_SOURCE_DIR", loc); } const char* cmState::Directory::GetCurrentBinary() const @@ -984,7 +984,7 @@ void cmState::Directory::SetCurrentBinary(std::string const& dir) loc, this->DirectoryState->CurrentBinaryDirectoryComponents); this->ComputeRelativePathTopBinary(); - this->Snapshot_.SetDefinition("CMAKE_CURRENT_BINARY_DIR", loc.c_str()); + this->Snapshot_.SetDefinition("CMAKE_CURRENT_BINARY_DIR", loc); } void cmState::Snapshot::SetListFile(const std::string& listfile) @@ -1380,8 +1380,8 @@ void cmState::Snapshot::InitializeFromParent_ForSubdirsCommand() this->SetDefinition("CMAKE_SOURCE_DIR", this->State->GetSourceDirectory()); this->SetDefinition("CMAKE_BINARY_DIR", this->State->GetBinaryDirectory()); - this->SetDefinition("CMAKE_CURRENT_SOURCE_DIR", currentSrcDir.c_str()); - this->SetDefinition("CMAKE_CURRENT_BINARY_DIR", currentBinDir.c_str()); + this->SetDefinition("CMAKE_CURRENT_SOURCE_DIR", currentSrcDir); + this->SetDefinition("CMAKE_CURRENT_BINARY_DIR", currentBinDir); } cmState::Directory::Directory( |