https://github.com/python/cpython/commit/9d5543ae702938beaeb349a47103c59b275c6ef3
commit: 9d5543ae702938beaeb349a47103c59b275c6ef3
branch: 3.13
author: Miss Islington (bot) <[email protected]>
committer: colesbury <[email protected]>
date: 2025-06-04T13:16:09Z
summary:

[3.13] gh-135108: Fix utmp.h inclusion in posixmodule.c on NetBSD (GH-135109) 
(GH-135128)

(cherry picked from commit 5b3865418ceb1448bfbf15cddf52c900cd5882a3)

Co-authored-by: Furkan Onder <[email protected]>

files:
M Modules/posixmodule.c

diff --git a/Modules/posixmodule.c b/Modules/posixmodule.c
index 8d5139887b1d0a..dc7d1e8d63be1f 100644
--- a/Modules/posixmodule.c
+++ b/Modules/posixmodule.c
@@ -8722,14 +8722,14 @@ os_ptsname_impl(PyObject *module, int fd)
 #if defined(HAVE_OPENPTY) || defined(HAVE_FORKPTY) || defined(HAVE_LOGIN_TTY) 
|| defined(HAVE_DEV_PTMX)
 #ifdef HAVE_PTY_H
 #include <pty.h>
-#ifdef HAVE_UTMP_H
-#include <utmp.h>
-#endif /* HAVE_UTMP_H */
 #elif defined(HAVE_LIBUTIL_H)
 #include <libutil.h>
 #elif defined(HAVE_UTIL_H)
 #include <util.h>
 #endif /* HAVE_PTY_H */
+#ifdef HAVE_UTMP_H
+#include <utmp.h>
+#endif /* HAVE_UTMP_H */
 #ifdef HAVE_STROPTS_H
 #include <stropts.h>
 #endif

_______________________________________________
Python-checkins mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3//lists/python-checkins.python.org
Member address: [email protected]

Reply via email to