]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
gh-141817: Add IPV6_HDRINCL constant to the socket module (#141818)
authorChris Angelico <rosuav@gmail.com>
Sat, 22 Nov 2025 17:07:21 +0000 (04:07 +1100)
committerGitHub <noreply@github.com>
Sat, 22 Nov 2025 17:07:21 +0000 (18:07 +0100)
Co-authored-by: Victor Stinner <vstinner@python.org>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
Doc/library/socket.rst
Misc/NEWS.d/next/Library/2025-11-21-21-14-10.gh-issue-141817._v5LdB.rst [new file with mode: 0644]
Modules/socketmodule.c

index 89bca9b5b20df7cdd22536a64729d0623145b813..976136885eac1b9848fb2f2b27f5e8fcd9566176 100644 (file)
@@ -482,6 +482,9 @@ The AF_* and SOCK_* constants are now :class:`AddressFamily` and
    .. versionchanged:: 3.14
       Added support for ``TCP_QUICKACK`` on Windows platforms when available.
 
+   .. versionchanged:: next
+      ``IPV6_HDRINCL`` was added.
+
 
 .. data:: AF_CAN
           PF_CAN
diff --git a/Misc/NEWS.d/next/Library/2025-11-21-21-14-10.gh-issue-141817._v5LdB.rst b/Misc/NEWS.d/next/Library/2025-11-21-21-14-10.gh-issue-141817._v5LdB.rst
new file mode 100644 (file)
index 0000000..774e13b
--- /dev/null
@@ -0,0 +1 @@
+Add :data:`!socket.IPV6_HDRINCL` constant.
index 6a844d44bf085b4b94a2bfebe716ee5ee7fad724..1ef359cb265ed46194cf9369123bb98c930417ff 100644 (file)
@@ -8901,6 +8901,9 @@ socket_exec(PyObject *m)
 #ifdef IPV6_HOPLIMIT
     ADD_INT_MACRO(m, IPV6_HOPLIMIT);
 #endif
+#ifdef IPV6_HDRINCL
+    ADD_INT_MACRO(m, IPV6_HDRINCL);
+#endif
 #ifdef IPV6_HOPOPTS
     ADD_INT_MACRO(m, IPV6_HOPOPTS);
 #endif