Fix Windows sock share (#2635)
This commit is contained in:
parent
4744a89c33
commit
911485d52e
|
@ -200,7 +200,7 @@ def _serve_http_1(
|
|||
asyncio_server_kwargs = (
|
||||
asyncio_server_kwargs if asyncio_server_kwargs else {}
|
||||
)
|
||||
if OS_IS_WINDOWS:
|
||||
if OS_IS_WINDOWS and sock:
|
||||
pid = os.getpid()
|
||||
sock = sock.share(pid)
|
||||
sock = socket.fromshare(sock)
|
||||
|
|
Loading…
Reference in New Issue
Block a user