mirror of
https://github.com/python/cpython.git
synced 2025-09-26 10:19:53 +00:00
[3.12] bpo-43952: Fix multiprocessing Listener authkey bug (GH-25845) (GH-115995)
Listener.accept() no longer hangs when authkey is an empty bytes object.
(cherry picked from commit 686ec17f50
)
Co-authored-by: Miguel Brito <5544985+miguendes@users.noreply.github.com>
This commit is contained in:
parent
96f98d9777
commit
3af945fbb4
3 changed files with 23 additions and 1 deletions
|
@ -476,8 +476,9 @@ class Listener(object):
|
|||
'''
|
||||
if self._listener is None:
|
||||
raise OSError('listener is closed')
|
||||
|
||||
c = self._listener.accept()
|
||||
if self._authkey:
|
||||
if self._authkey is not None:
|
||||
deliver_challenge(c, self._authkey)
|
||||
answer_challenge(c, self._authkey)
|
||||
return c
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue