Issue #16953: Fix socket module compilation on platforms with HAVE_BROKEN_POLL.
Patch by Jeffrey Armstrong.
diff --git a/Modules/selectmodule.c b/Modules/selectmodule.c
index 3f846d8..7863aaa 100644
--- a/Modules/selectmodule.c
+++ b/Modules/selectmodule.c
@@ -1743,7 +1743,7 @@
 
 static PyMethodDef select_methods[] = {
     {"select",          select_select,  METH_VARARGS,   select_doc},
-#ifdef HAVE_POLL
+#if defined(HAVE_POLL) && !defined(HAVE_BROKEN_POLL)
     {"poll",            select_poll,    METH_NOARGS,    poll_doc},
 #endif /* HAVE_POLL */
     {0,         0},     /* sentinel */
@@ -1788,7 +1788,7 @@
     PyModule_AddIntConstant(m, "PIPE_BUF", PIPE_BUF);
 #endif
 
-#if defined(HAVE_POLL)
+#if defined(HAVE_POLL) && !defined(HAVE_BROKEN_POLL)
 #ifdef __APPLE__
     if (select_have_broken_poll()) {
         if (PyObject_DelAttrString(m, "poll") == -1) {