[PATCH/cygwin] reduce number of propagated environment variables

Corinna Vinschen vinschen at redhat.com
Sat Feb 20 04:37:31 EST 2010


Hi,

could somebody apply the below patch, please?  It removes a couple of
environment variables which are propagated to the child process so far,
but which not really necessary to keep child processes running.  What's
left now is the bare minimum which is requested by scripts, typically.


Thanks,
Corinna


Index: openbsd-compat/bsd-cygwin_util.c
===================================================================
RCS file: /cvs/openssh/openbsd-compat/bsd-cygwin_util.c,v
retrieving revision 1.21
diff -u -p -r1.21 bsd-cygwin_util.c
--- openbsd-compat/bsd-cygwin_util.c	8 Mar 2009 00:40:28 -0000	1.21
+++ openbsd-compat/bsd-cygwin_util.c	19 Feb 2010 17:35:28 -0000
@@ -85,23 +85,14 @@ static struct wenv {
 	size_t namelen;
 } wenv_arr[] = {
 	{ NL("ALLUSERSPROFILE=") },
-	{ NL("COMMONPROGRAMFILES=") },
 	{ NL("COMPUTERNAME=") },
 	{ NL("COMSPEC=") },
 	{ NL("CYGWIN=") },
-	{ NL("NUMBER_OF_PROCESSORS=") },
 	{ NL("OS=") },
 	{ NL("PATH=") },
 	{ NL("PATHEXT=") },
-	{ NL("PROCESSOR_ARCHITECTURE=") },
-	{ NL("PROCESSOR_IDENTIFIER=") },
-	{ NL("PROCESSOR_LEVEL=") },
-	{ NL("PROCESSOR_REVISION=") },
-	{ NL("PROGRAMFILES=") },
 	{ NL("SYSTEMDRIVE=") },
 	{ NL("SYSTEMROOT=") },
-	{ NL("TMP=") },
-	{ NL("TEMP=") },
 	{ NL("WINDIR=") }
 };
 

-- 
Corinna Vinschen
Cygwin Project Co-Leader
Red Hat


More information about the openssh-unix-dev mailing list