summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--CMakeLists.txt3
-rw-r--r--SystemTools.cxx4
2 files changed, 5 insertions, 2 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 52bcfe1..977d57b 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -85,6 +85,9 @@
# written.
CMAKE_MINIMUM_REQUIRED(VERSION 2.6.3 FATAL_ERROR)
+IF(POLICY CMP0025)
+ CMAKE_POLICY(SET CMP0025 NEW)
+ENDIF()
#-----------------------------------------------------------------------------
# If a namespace is not specified, use "kwsys" and enable testing.
diff --git a/SystemTools.cxx b/SystemTools.cxx
index b6a2437..32e79e6 100644
--- a/SystemTools.cxx
+++ b/SystemTools.cxx
@@ -4918,8 +4918,8 @@ void SystemTools::ClassInitialize()
// Strip off one directory level and see if the logical
// mapping still works.
- pwd_str = SystemTools::GetFilenamePath(pwd_str.c_str());
- cwd_str = SystemTools::GetFilenamePath(cwd_str.c_str());
+ pwd_str = SystemTools::GetFilenamePath(pwd_str);
+ cwd_str = SystemTools::GetFilenamePath(cwd_str);
Realpath(pwd_str.c_str(), pwd_path);
}