Skip to content

Commit b6c147c

Browse files
committed
skip shadow call when euid > 0 on linux
maybe __linux__ is not restrictive enough and we could consider using a hint sh file to enable it only on some specific distro?
1 parent 032639c commit b6c147c

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

pp_sys.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5562,7 +5562,11 @@ PP(pp_gpwent)
55625562
* --jhi */
55635563
/* Some AIX setups falsely(?) detect some getspnam(), which
55645564
* has a different API than the Solaris/IRIX one. */
5565+
55655566
# if defined(HAS_GETSPNAM) && !defined(_AIX)
5567+
# ifdef __linux__
5568+
if (!PerlProc_geteuid())
5569+
# endif
55665570
{
55675571
dSAVE_ERRNO;
55685572
const struct spwd * const spwent = getspnam(pwent->pw_name);

0 commit comments

Comments
 (0)