[RFA/mingw32] environment variables are case-insensitive on win32

Jerome Guitton guitton@adacore.com
Fri Dec 14 10:55:00 GMT 2012


Pierre Muller (pierre.muller@ics-cnrs.unistra.fr):

>   Coming back to the mingw32 case,
> currently you can perfectly pass both Path and PATH environment variables to debuggee.
>   If this debuggee is cmd.exe, the funny thing is that it will use
> the value of Path rather than that of PATH ....

Even worse: 'set' would list the two variables, but if you do 'echo
%PATH%' or 'echo %Path%' you'll get the same value (the first one in
the list of environment variables, apparently):

c:\home\guitton\GIT\GDB\builds> set
[...]
PATH=C:\cygwin\bin
Path=C:\windows\system32
[...]

c:\home\guitton\GIT\GDB\builds> echo %PATH%
C:\cygwin\bin

c:\home\guitton\GIT\GDB\builds> echo %Path%
C:\cygwin\bin

My feeling is that all sort of strange things can happen if we do not
assume case-insensitivity in the context of mingw32, so we'd better
stick to it. What do you think?



More information about the Gdb-patches mailing list