summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard Oudkerk <shibturn@gmail.com>2014-07-28 22:01:02 (GMT)
committerRichard Oudkerk <shibturn@gmail.com>2014-07-28 22:01:02 (GMT)
commite0e65817e534420d5d04a635f964d97abf68e921 (patch)
tree8a95626dc95ec57a0bb07d498c630a3350079cf9
parent7611964b2cb82e38f3354e665bbe6c9e7efa8cb6 (diff)
downloadcpython-e0e65817e534420d5d04a635f964d97abf68e921.zip
cpython-e0e65817e534420d5d04a635f964d97abf68e921.tar.gz
cpython-e0e65817e534420d5d04a635f964d97abf68e921.tar.bz2
Issue #21704: Fix build error for _multiprocessing when semaphores
are not available. Patch by Arfrever Frehtes Taifersar Arahesis.
-rw-r--r--Misc/ACKS1
-rw-r--r--Misc/NEWS3
-rw-r--r--Modules/_multiprocessing/multiprocessing.c2
3 files changed, 6 insertions, 0 deletions
diff --git a/Misc/ACKS b/Misc/ACKS
index fdf89d4..edd144c 100644
--- a/Misc/ACKS
+++ b/Misc/ACKS
@@ -51,6 +51,7 @@ Ankur Ankan
Jon Anglin
Heidi Annexstad
Ramchandra Apte
+Arfrever Frehtes Taifersar Arahesis
Éric Araujo
Alicia Arlen
Jeffrey Armstrong
diff --git a/Misc/NEWS b/Misc/NEWS
index 9f7ca1d..92c9cb6 100644
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -27,6 +27,9 @@ Core and Builtins
Library
-------
+- Issue #21704: Fix build error for _multiprocessing when semaphores
+ are not available. Patch by Arfrever Frehtes Taifersar Arahesis.
+
- Fix repr(_socket.socket) on Windows 64-bit: don't fail with OverflowError
on closed socket. repr(socket.socket) already works fine.
diff --git a/Modules/_multiprocessing/multiprocessing.c b/Modules/_multiprocessing/multiprocessing.c
index 1aaf360..4ae638e 100644
--- a/Modules/_multiprocessing/multiprocessing.c
+++ b/Modules/_multiprocessing/multiprocessing.c
@@ -128,7 +128,9 @@ static PyMethodDef module_methods[] = {
{"recv", multiprocessing_recv, METH_VARARGS, ""},
{"send", multiprocessing_send, METH_VARARGS, ""},
#endif
+#ifndef POSIX_SEMAPHORES_NOT_ENABLED
{"sem_unlink", _PyMp_sem_unlink, METH_VARARGS, ""},
+#endif
{NULL}
};