make-w32
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Minor patch to correct buffer overrun


From: Chris Sutcliffe
Subject: Re: Minor patch to correct buffer overrun
Date: Thu, 26 Aug 2010 12:50:26 -0400

On 26 August 2010 12:29, Eli Zaretskii wrote:
> HAVE_DOS_PATHS is supported in the Cygwin build as well, and there
> PATH_SEPARATOR_CHAR must stay ':'.  So please modify your patch to
> exclude Cygwin from its effect, and then I'll agree to its
> HAVE_DOS_PATHS part.  I leave the rest to VMS expert and to Paul.

Fair enough, please have a look at the modified patch below:

--- make.h.orig 2010-07-20 09:12:06 -0400
+++ make.h      2010-08-26 12:44:45 -0400
@@ -306,13 +306,17 @@
 #define S_(msg1,msg2,num)   ngettext (msg1,msg2,num)

 /* Handle other OSs.  */
-#ifndef PATH_SEPARATOR_CHAR
-# if defined(HAVE_DOS_PATHS)
-#  define PATH_SEPARATOR_CHAR ';'
-# elif defined(VMS)
-#  define PATH_SEPARATOR_CHAR ','
+/* To overcome an issue parsing paths in a DOS/Windows environment when */
+/* built in a unix based environment, override the PATH_SEPARATOR_CHAR  */
+/* definition unless being built for Cygwin.                            */
+#if defined(HAVE_DOS_PATHS) && !defined(__CYGWIN__)
+# undef PATH_SEPARATOR_CHAR
+# define PATH_SEPARATOR_CHAR ';'
+#elif !defined(PATH_SEPARATOR_CHAR)
+# if defined (VMS)
+#   define PATH_SEPARATOR_CHAR ','
 # else
-#  define PATH_SEPARATOR_CHAR ':'
+#   define PATH_SEPARATOR_CHAR ':'
 # endif
 #endif

I opted to leave the VMS piece working the way it did before, taking
the "if it ain't broke don't fix it" approach.  Is the comment
appropriate?

Thank you,

Chris

-- 
Chris Sutcliffe
http://emergedesktop.org
http://www.google.com/profiles/ir0nh34d



reply via email to

[Prev in Thread] Current Thread [Next in Thread]