Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 3e11b5c

Browse files
[3.13] gh-93312: Include <sys/pidfd.h> to get PIDFD_NONBLOCK (GH-127593) (#127630)
gh-93312: Include <sys/pidfd.h> to get PIDFD_NONBLOCK (GH-127593) (cherry picked from commit fcbe6ec) Co-authored-by: Victor Stinner <[email protected]>
1 parent 1182c64 commit 3e11b5c

File tree

5 files changed

+15
-1
lines changed

5 files changed

+15
-1
lines changed
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
Include ``<sys/pidfd.h>`` to get ``os.PIDFD_NONBLOCK`` constant. Patch by
2+
Victor Stinner.

Modules/posixmodule.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,9 @@
7373
#ifdef HAVE_SYS_TIME_H
7474
# include <sys/time.h> // futimes()
7575
#endif
76+
#ifdef HAVE_SYS_PIDFD_H
77+
# include <sys/pidfd.h> // PIDFD_NONBLOCK
78+
#endif
7679

7780

7881
// SGI apparently needs this forward declaration

configure

Lines changed: 6 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

configure.ac

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2985,7 +2985,7 @@ AC_CHECK_HEADERS([ \
29852985
linux/tipc.h linux/wait.h netdb.h net/ethernet.h netinet/in.h netpacket/packet.h poll.h process.h pthread.h pty.h \
29862986
sched.h setjmp.h shadow.h signal.h spawn.h stropts.h sys/audioio.h sys/bsdtty.h sys/devpoll.h \
29872987
sys/endian.h sys/epoll.h sys/event.h sys/eventfd.h sys/file.h sys/ioctl.h sys/kern_control.h \
2988-
sys/loadavg.h sys/lock.h sys/memfd.h sys/mkdev.h sys/mman.h sys/modem.h sys/param.h sys/poll.h \
2988+
sys/loadavg.h sys/lock.h sys/memfd.h sys/mkdev.h sys/mman.h sys/modem.h sys/param.h sys/pidfd.h sys/poll.h \
29892989
sys/random.h sys/resource.h sys/select.h sys/sendfile.h sys/socket.h sys/soundcard.h sys/stat.h \
29902990
sys/statvfs.h sys/sys_domain.h sys/syscall.h sys/sysmacros.h sys/termio.h sys/time.h sys/times.h sys/timerfd.h \
29912991
sys/types.h sys/uio.h sys/un.h sys/utsname.h sys/wait.h sys/xattr.h sysexits.h syslog.h \

pyconfig.h.in

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1385,6 +1385,9 @@
13851385
/* Define to 1 if you have the <sys/param.h> header file. */
13861386
#undef HAVE_SYS_PARAM_H
13871387

1388+
/* Define to 1 if you have the <sys/pidfd.h> header file. */
1389+
#undef HAVE_SYS_PIDFD_H
1390+
13881391
/* Define to 1 if you have the <sys/poll.h> header file. */
13891392
#undef HAVE_SYS_POLL_H
13901393

0 commit comments

Comments
 (0)