Skip to content

Commit 1b95783

Browse files
committed
Use PerlLIO_dup_cloexec in Perl_dirp_dup to set O_CLOEXEC
1 parent 6fbe2c7 commit 1b95783

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

sv.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14111,7 +14111,7 @@ Perl_dirp_dup(pTHX_ DIR *const dp, CLONE_PARAMS *const param)
1411114111

1411214112
PERL_UNUSED_ARG(param);
1411314113

14114-
ret = fdopendir(dup(my_dirfd(dp)));
14114+
ret = fdopendir(PerlLIO_dup_cloexec(my_dirfd(dp)));
1411514115

1411614116
#elif defined(WIN32)
1411714117
ret = win32_dirp_dup(dp, param);

0 commit comments

Comments
 (0)