[cmake-commits] king committed cmFileCommand.cxx 1.93 1.94

cmake-commits at cmake.org cmake-commits at cmake.org
Fri Jan 4 14:22:59 EST 2008


Update of /cvsroot/CMake/CMake/Source
In directory public:/mounts/ram/cvs-serv28707/Source

Modified Files:
	cmFileCommand.cxx 
Log Message:
BUG: File installation should overwrite the destination if the file times differ at all rather than only if the source file is newer.  Users expect installation to overwrite destination files.  This addresses the re-opening of bug#3349.


Index: cmFileCommand.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmFileCommand.cxx,v
retrieving revision 1.93
retrieving revision 1.94
diff -u -d -r1.93 -r1.94
--- cmFileCommand.cxx	3 Jan 2008 14:40:38 -0000	1.93
+++ cmFileCommand.cxx	4 Jan 2008 19:22:57 -0000	1.94
@@ -949,11 +949,8 @@
   bool copy = true;
   if(!always)
     {
-    // If both files exist and "fromFile" is not newer than "toFile"
-    // do not copy.
-    int timeResult;
-    if(this->FileTimes.FileTimeCompare(fromFile, toFile, &timeResult) &&
-       timeResult <= 0)
+    // If both files exist with the same time do not copy.
+    if(!this->FileTimes.FileTimesDiffer(fromFile, toFile))
       {
       copy = false;
       }



More information about the Cmake-commits mailing list