[Cmake-commits] [cmake-commits] king committed System.c 1.12 1.13
cmake-commits at cmake.org
cmake-commits at cmake.org
Wed Apr 30 15:58:47 EDT 2008
Update of /cvsroot/CMake/CMake/Source/kwsys
In directory public:/mounts/ram/cvs-serv2148/Source/kwsys
Modified Files:
System.c
Log Message:
BUG: Fix escaping of more characters on Windows shells.
Index: System.c
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/kwsys/System.c,v
retrieving revision 1.12
retrieving revision 1.13
diff -C 2 -d -r1.12 -r1.13
*** System.c 30 Apr 2008 14:02:08 -0000 1.12
--- System.c 30 Apr 2008 19:58:45 -0000 1.13
***************
*** 76,79 ****
--- 76,86 ----
/*--------------------------------------------------------------------------*/
+ static int kwsysSystem_Shell__CharNeedsQuotesOnWindows(char c)
+ {
+ return ((c == '\'') || (c == '#') || (c == '&') ||
+ (c == '<') || (c == '>') || (c == '|') || (c == '^'));
+ }
+
+ /*--------------------------------------------------------------------------*/
static int kwsysSystem_Shell__CharNeedsQuotes(char c, int isUnix, int flags)
{
***************
*** 100,111 ****
else
{
! /* On Windows single-quotes must be escaped in some make
! environments, such as in mingw32-make. */
! if(flags & kwsysSystem_Shell_Flag_Make)
{
! if(c == '\'')
! {
! return 1;
! }
}
}
--- 107,114 ----
else
{
! /* On Windows several special characters need quotes to preserve them. */
! if(kwsysSystem_Shell__CharNeedsQuotesOnWindows(c))
{
! return 1;
}
}
More information about the Cmake-commits
mailing list