bpo-31893: Fix errors in b9052a0f91d2e83bbc27267247a5920c82b242a3. (#4196)
authorSerhiy Storchaka <storchaka@gmail.com>
Tue, 31 Oct 2017 16:18:21 +0000 (18:18 +0200)
committerGitHub <noreply@github.com>
Tue, 31 Oct 2017 16:18:21 +0000 (18:18 +0200)
* Fix a compilation error on FreeBSD.
* Fix the data attribute size on Mac OS X.

Modules/selectmodule.c

index af265d89ff6e2e61bbcba4c34207c20d3ad39d82..1cde6e849c4c53f598245f6b53ce1e9ee3b46f1e 100644 (file)
@@ -1840,12 +1840,12 @@ static PyTypeObject kqueue_queue_Type;
 #   define FFLAGS_FMT_UNIT  "I"
 #endif
 
-#ifdef __FreeBSD__
-#   define DATA_TYPE        T_INTPTRT
-#   define DATA_FMT_UNIT    INTPTR_FMT_UNIT
-#else
+#if defined(__NetBSD__) || defined(__OpenBSD__)
 #   define DATA_TYPE        T_INT64
 #   define DATA_FMT_UNIT    INT64_FMT_UNIT
+#else
+#   define DATA_TYPE        T_INTPTRT
+#   define DATA_FMT_UNIT    INTPTRT_FMT_UNIT
 #endif
 
 /* Unfortunately, we can't store python objects in udata, because