File tree Expand file tree Collapse file tree 1 file changed +7
-0
lines changed
Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Original file line number Diff line number Diff line change @@ -5436,6 +5436,9 @@ PP(pp_gpwent)
54365436 I32 which = PL_op -> op_type ;
54375437 SV * sv ;
54385438 struct passwd * pwent = NULL ;
5439+ #ifdef __linux__
5440+ const Uid_t euid = geteuid ();
5441+ #endif
54395442 /*
54405443 * We currently support only the SysV getsp* shadow password interface.
54415444 * The interface is declared in <shadow.h> and often one needs to link
@@ -5562,7 +5565,11 @@ PP(pp_gpwent)
55625565 * --jhi */
55635566 /* Some AIX setups falsely(?) detect some getspnam(), which
55645567 * has a different API than the Solaris/IRIX one. */
5568+
55655569# if defined(HAS_GETSPNAM ) && !defined(_AIX )
5570+ # ifdef __linux__
5571+ if (!PerlProc_geteuid ())
5572+ # endif
55665573 {
55675574 dSAVE_ERRNO ;
55685575 const struct spwd * const spwent = getspnam (pwent -> pw_name );
You can’t perform that action at this time.
0 commit comments