Concise JEMALLOC_HAVE_ISSETUGID case in secure_getenv().
This commit is contained in:
parent
897503521d
commit
95e88de0aa
@ -709,24 +709,16 @@ stats_print_atexit(void)
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#ifndef JEMALLOC_HAVE_SECURE_GETENV
|
#ifndef JEMALLOC_HAVE_SECURE_GETENV
|
||||||
|
static char *
|
||||||
|
secure_getenv(const char *name)
|
||||||
|
{
|
||||||
|
|
||||||
# ifdef JEMALLOC_HAVE_ISSETUGID
|
# ifdef JEMALLOC_HAVE_ISSETUGID
|
||||||
static char *
|
if (issetugid() != 0)
|
||||||
secure_getenv(const char *name)
|
|
||||||
{
|
|
||||||
|
|
||||||
if (issetugid() == 0)
|
|
||||||
return (getenv(name));
|
|
||||||
else
|
|
||||||
return (NULL);
|
return (NULL);
|
||||||
}
|
# endif
|
||||||
# else
|
|
||||||
static char *
|
|
||||||
secure_getenv(const char *name)
|
|
||||||
{
|
|
||||||
|
|
||||||
return (getenv(name));
|
return (getenv(name));
|
||||||
}
|
}
|
||||||
# endif
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
static unsigned
|
static unsigned
|
||||||
|
Loading…
Reference in New Issue
Block a user