From 2fc69ba0b33e8f5f1b6301f37fc1479fba420b93 Mon Sep 17 00:00:00 2001 From: Vitaly Stakhovsky Date: Mon, 28 Jan 2019 09:00:28 -0500 Subject: cmFileTimeComparison: use std::string arguments --- Source/cmDepends.cxx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'Source/cmDepends.cxx') diff --git a/Source/cmDepends.cxx b/Source/cmDepends.cxx index 976ba5701f..7d1d316249 100644 --- a/Source/cmDepends.cxx +++ b/Source/cmDepends.cxx @@ -156,8 +156,8 @@ bool cmDepends::CheckDependencies( // * if the depender does not exist, but the dependee is newer than the // depends file bool regenerate = false; - const char* dependee = this->Dependee + 1; - const char* depender = this->Depender; + const std::string dependee(this->Dependee + 1); + const std::string depender(this->Depender); if (currentDependencies != nullptr) { currentDependencies->push_back(dependee); } @@ -195,8 +195,8 @@ bool cmDepends::CheckDependencies( // The dependee exists, but the depender doesn't. Regenerate if the // internalDepends file is older than the dependee. int result = 0; - if ((!this->FileComparison->FileTimeCompare( - internalDependsFileName.c_str(), dependee, &result) || + if ((!this->FileComparison->FileTimeCompare(internalDependsFileName, + dependee, &result) || result < 0)) { // The depends-file is older than the dependee. regenerate = true; -- cgit v1.2.1