[cmake-commits] hoffman committed SystemTools.cxx 1.198 1.199

cmake-commits at cmake.org cmake-commits at cmake.org
Wed Jun 6 10:44:22 EDT 2007


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

Modified Files:
	SystemTools.cxx 
Log Message:
ENH: fix case problem with drive letters and cmake vs CMakeSetup build.make changing


Index: SystemTools.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/kwsys/SystemTools.cxx,v
retrieving revision 1.198
retrieving revision 1.199
diff -u -d -r1.198 -r1.199
--- SystemTools.cxx	12 Mar 2007 17:50:28 -0000	1.198
+++ SystemTools.cxx	6 Jun 2007 14:44:20 -0000	1.199
@@ -154,6 +154,11 @@
     fprintf(stderr, "No current working directory.\n");
     abort();
     }
+  // make sure the drive letter is capital
+  if(strlen(buf) > 1 && buf[1] == ':')
+    {
+    buf[0] = toupper(buf[0]);
+    }
   return ret;
 }
 inline int Chdir(const char* dir)
@@ -2875,6 +2880,11 @@
     {
     return p;
     }
+  // make sure drive letter is always upper case
+  if(longPath.size() > 1 && longPath[1] == ':')
+    {
+    longPath[0] = toupper(longPath[0]);
+    }
   return longPath;
 #endif  
 }



More information about the Cmake-commits mailing list