mirror of
https://github.com/python/cpython.git
synced 2025-07-28 21:55:21 +00:00
Bug #1531963: Make SocketServer.TCPServer's server_address always be equal to calling getsockname() on the server's socket.
Will backport.
This commit is contained in:
parent
dbead56cb6
commit
22c42ba88c
3 changed files with 5 additions and 0 deletions
|
@ -84,6 +84,7 @@ class ServerThread(threading.Thread):
|
|||
addr = getattr(svr, 'server_address')
|
||||
if addr:
|
||||
self.__addr = addr
|
||||
assert self.__addr == svr.socket.getsockname()
|
||||
if verbose: print "thread: serving three times"
|
||||
svr.serve_a_few()
|
||||
if verbose: print "thread: done"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue