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

Jerome Guitton
2012-12-10T17:16:52Z

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

> $ cat testenv.c
> #include "stdio.h"
>
> int
> main (int argc, char **argv, char **env)
> {
> int envindex = 1;
> char *curr_env = *env;
>
> while (curr_env)
> {
> printf("env#%d is %s\n",envindex,curr_env);
> curr_env = env [envindex];
> envindex++;
> }
> return 0;
> }

Hmm. I can reproduce the problem. I'm thinking that the env vector (as
main's third argument) may be passed to the program by createInferior
without any processing. If you try getenv, I bet that you'll have a
different result.