]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
gh-133568: Only set `HAVE_AF_HYPERV` on supported WinAPI partitions (GH-133569)
authorMax Bachmann <max.bachmann@iracing.com>
Wed, 14 May 2025 11:42:33 +0000 (13:42 +0200)
committerGitHub <noreply@github.com>
Wed, 14 May 2025 11:42:33 +0000 (11:42 +0000)
Misc/NEWS.d/next/Windows/2025-05-07-11-25-29.gh-issue-133568.oYV0d8.rst [new file with mode: 0644]
Modules/socketmodule.h

diff --git a/Misc/NEWS.d/next/Windows/2025-05-07-11-25-29.gh-issue-133568.oYV0d8.rst b/Misc/NEWS.d/next/Windows/2025-05-07-11-25-29.gh-issue-133568.oYV0d8.rst
new file mode 100644 (file)
index 0000000..1e2a5b5
--- /dev/null
@@ -0,0 +1 @@
+Fix compile error when using a WinAPI partition that doesn't support the RPC runtime library.
index 63624d511c35a058b6a51e9c8c2dafbf0dc7a24d..200b2b8c7d8310cd49fd4d1371154e507d4723a2 100644 (file)
@@ -259,7 +259,7 @@ typedef int SOCKET_T;
 #endif
 
 // AF_HYPERV is only supported on Windows
-#if defined(AF_HYPERV) && defined(MS_WINDOWS)
+#if defined(AF_HYPERV) && (defined(MS_WINDOWS_APP) || defined(MS_WINDOWS_SYSTEM))
 #  define HAVE_AF_HYPERV
 #endif