From 0dee9f4972523ad3bff54f1c161767dcf7d6d65c Mon Sep 17 00:00:00 2001 From: adder32 Date: Sun, 12 Nov 2023 02:08:23 +0100 Subject: [PATCH 1/2] Add getnameinfo extension flag --- Modules/socketmodule.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Modules/socketmodule.c b/Modules/socketmodule.c index 97f4d174666750..c0cd5d429e7fb1 100644 --- a/Modules/socketmodule.c +++ b/Modules/socketmodule.c @@ -8809,6 +8809,9 @@ socket_exec(PyObject *m) #ifdef NI_DGRAM ADD_INT_MACRO(m, NI_DGRAM); #endif +#ifdef NI_IDN + ADD_INT_MACRO(m, NI_IDN); +#endif /* shutdown() parameters */ #ifdef SHUT_RD From a5d58a192070b6988132c2cbbd7a8c040b06a73c Mon Sep 17 00:00:00 2001 From: "Gregory P. Smith [Google LLC]" Date: Tue, 14 Nov 2023 16:32:04 -0800 Subject: [PATCH 2/2] NEWS blurb --- .../next/Library/2023-11-14-16-31-59.gh-issue-111995.OoX8JJ.rst | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 Misc/NEWS.d/next/Library/2023-11-14-16-31-59.gh-issue-111995.OoX8JJ.rst diff --git a/Misc/NEWS.d/next/Library/2023-11-14-16-31-59.gh-issue-111995.OoX8JJ.rst b/Misc/NEWS.d/next/Library/2023-11-14-16-31-59.gh-issue-111995.OoX8JJ.rst new file mode 100644 index 00000000000000..773f620c97b608 --- /dev/null +++ b/Misc/NEWS.d/next/Library/2023-11-14-16-31-59.gh-issue-111995.OoX8JJ.rst @@ -0,0 +1,2 @@ +Added the ``NI_IDN`` constant to the :mod:`socket` module when present in C +at build time for use with :func:`socket.getnameinfo`.