summaryrefslogtreecommitdiffstats
path: root/Doc/library/threading.rst
diff options
context:
space:
mode:
authorCharles-François Natali <neologix@free.fr>2012-01-07 17:26:39 (GMT)
committerCharles-François Natali <neologix@free.fr>2012-01-07 17:26:39 (GMT)
commit61d28d6a740dac9705ae5b1efc7cb67a9a110bf1 (patch)
treec4a52adb3ce2ce12edbd598cf5152d9fffc2ffb3 /Doc/library/threading.rst
parent5e60857e91056e5bb4a22783c31eaa3153cac051 (diff)
parentded0348c08f298fda4426eb2a62cc3d50eed25b5 (diff)
downloadcpython-61d28d6a740dac9705ae5b1efc7cb67a9a110bf1.zip
cpython-61d28d6a740dac9705ae5b1efc7cb67a9a110bf1.tar.gz
cpython-61d28d6a740dac9705ae5b1efc7cb67a9a110bf1.tar.bz2
Issue #13502: threading: Fix a race condition in Event.wait() that made it
return False when the event was set and cleared right after.
Diffstat (limited to 'Doc/library/threading.rst')
-rw-r--r--Doc/library/threading.rst6
1 files changed, 4 insertions, 2 deletions
diff --git a/Doc/library/threading.rst b/Doc/library/threading.rst
index aaec588..2b43ee5 100644
--- a/Doc/library/threading.rst
+++ b/Doc/library/threading.rst
@@ -804,8 +804,10 @@ An event object manages an internal flag that can be set to true with the
floating point number specifying a timeout for the operation in seconds
(or fractions thereof).
- This method returns the internal flag on exit, so it will always return
- ``True`` except if a timeout is given and the operation times out.
+ This method returns true if and only if the internal flag has been set to
+ true, either before the wait call or after the wait starts, so it will
+ always return ``True`` except if a timeout is given and the operation
+ times out.
.. versionchanged:: 3.1
Previously, the method always returned ``None``.