* environ.cc (spenv::from_cygheap): Still need to take setuid into

consideration.
This commit is contained in:
Christopher Faylor 2002-06-29 06:40:19 +00:00
parent e97962b92a
commit 664075a3bb
2 changed files with 7 additions and 2 deletions

View File

@ -1,3 +1,8 @@
2002-06-29 Christopher Faylor <cgf@redhat.com>
* environ.cc (spenv::from_cygheap): Still need to take setuid into
consideration.
2002-06-28 Christopher Faylor <cgf@redhat.com> 2002-06-28 Christopher Faylor <cgf@redhat.com>
* uinfo.cc (cygheap_user::env_logsrv): Return "almost_null" in case * uinfo.cc (cygheap_user::env_logsrv): Return "almost_null" in case
@ -13,7 +18,7 @@
* cygheap.cc (cygheap_user::set_name): Reflect name "pwinname" name * cygheap.cc (cygheap_user::set_name): Reflect name "pwinname" name
change. change.
* environ.cc (getwinenveq): New function. * environ.cc (getwinenveq): New function.
(spenv::from_cygheap): Change arguments. (penv::from_cygheap): penv::from_cygheap): Change arguments.
(spenv::retrieve): Ditto for call. Use getwinenveq to retrieve info (spenv::retrieve): Ditto for call. Use getwinenveq to retrieve info
from environment. Always return value from cygwin environment, if it from environment. Always return value from cygwin environment, if it
exists. exists.

View File

@ -817,7 +817,7 @@ spenv::retrieve (bool no_envblock, const char *const envname)
if (from_cygheap) if (from_cygheap)
{ {
const char *p; const char *p;
if (envname) if (envname && !cygheap->user.issetuid ())
{ {
debug_printf ("duping existing value for '%s'", name); debug_printf ("duping existing value for '%s'", name);
return cstrdup1 (envname); /* Don't really care what it's set to return cstrdup1 (envname); /* Don't really care what it's set to