* cygcheck.cc (load_cygwin): Don't touch $PATH for now.

(print_version): Fix copyright.
	* strace.cc (print_version): Ditto.
This commit is contained in:
Corinna Vinschen 2005-05-15 12:29:47 +00:00
parent 1f7b9e8bc6
commit 90253b8276
3 changed files with 20 additions and 5 deletions

View File

@ -1,3 +1,9 @@
2005-05-15 Corinna Vinschen <corinna@vinschen.de>
* cygcheck.cc (load_cygwin): Don't touch $PATH for now.
(print_version): Fix copyright.
* strace.cc (print_version): Ditto.
2005-05-13 Christopher Faylor <cgf@timesys.com>
* mount.cc (mount_commands): Display "-X" option when appropriate.

View File

@ -1,6 +1,6 @@
/* cygcheck.cc
Copyright 1998, 1999, 2000, 2001, 2002, 2003, 2004 Red Hat, Inc.
Copyright 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 Red Hat, Inc.
This file is part of Cygwin.
@ -1424,7 +1424,7 @@ print_version ()
printf ("\
cygcheck version %.*s\n\
System Checker for Cygwin\n\
Copyright 1998, 1999, 2000, 2001, 2002, 2003, 2004 Red Hat, Inc.\n\
Copyright 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 Red Hat, Inc.\n\
Compiled on %s\n\
", len, v, __DATE__);
}
@ -1459,10 +1459,19 @@ load_cygwin (int& argc, char **&argv)
char **envp = (char **) cygwin_internal (CW_ENVP);
if (envp)
{
/* Store path and revert to this value, otherwise path gets overwritten
by the POSIXy Cygwin variation, which breaks cygcheck.
Another approach would be to use the Cygwin PATH and convert it to
Win32 again. */
char *path = NULL;
while (*_environ)
nuke (*_environ);
{
if (!strncmp (*_environ, "PATH=", 5))
path = strdup (*_environ);
nuke (*_environ);
}
for (char **ev = envp; *ev; ev++)
putenv (*ev);
putenv (!strncmp (*ev, "PATH=", 5) ? path : *ev);
}
}

View File

@ -890,7 +890,7 @@ print_version ()
printf ("\
%s (cygwin) %.*s\n\
System Trace\n\
Copyright 2000, 2001, 2002, 2003, 2004 Red Hat, Inc.\n\
Copyright 2000, 2001, 2002, 2003, 2004, 2005 Red Hat, Inc.\n\
Compiled on %s\n\
", pgm, len, v, __DATE__);
}