aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJakub Kulík <Kulikjak@gmail.com>2024-09-17 19:06:53 +0200
committerMichał Górny <mgorny@gentoo.org>2024-09-19 06:22:37 +0200
commit4979be0e7bee0e4e12bc00e33223cbdd81423abf (patch)
treee2990b13fb9e662b18952ca2b8b20eb970c7816e
parentgh-110190: Fix ctypes structs with array on Windows ARM64 (GH-114753) (diff)
downloadcpython-4979be0e7bee0e4e12bc00e33223cbdd81423abf.tar.gz
cpython-4979be0e7bee0e4e12bc00e33223cbdd81423abf.tar.bz2
cpython-4979be0e7bee0e4e12bc00e33223cbdd81423abf.zip
gh-110190: Fix ctypes structs with array on SPARC (GH-118233)gentoo-3.8.20_p2
Signed-off-by: Michał Górny <mgorny@gentoo.org>
-rw-r--r--Modules/_ctypes/stgdict.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/_ctypes/stgdict.c b/Modules/_ctypes/stgdict.c
index 13e7a7668b5..dd3c5bd0fd2 100644
--- a/Modules/_ctypes/stgdict.c
+++ b/Modules/_ctypes/stgdict.c
@@ -656,7 +656,7 @@ PyCStructUnionType_update_stgdict(PyObject *type, PyObject *fields, int isStruct
/*
* The value of MAX_STRUCT_SIZE depends on the platform Python is running on.
*/
-#if defined(__aarch64__) || defined(__arm__) || defined(_M_ARM64)
+#if defined(__aarch64__) || defined(__arm__) || defined(_M_ARM64) || defined(__sparc__)
# define MAX_STRUCT_SIZE 32
#elif defined(__powerpc64__)
# define MAX_STRUCT_SIZE 64