We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 257aa24 commit fb6df12Copy full SHA for fb6df12
pymongo/network_layer.py
@@ -215,11 +215,11 @@ async def _async_receive_ssl(
215
while total_read < length:
216
try:
217
read = conn.recv_into(mv[total_read:])
218
+ if read == 0:
219
+ raise OSError("connection closed")
220
# KMS responses update their expected size after the first batch, stop reading after one loop
221
if once:
222
return mv[:read]
- if read == 0:
- raise OSError("connection closed")
223
except BLOCKING_IO_ERRORS:
224
await asyncio.sleep(backoff)
225
read = 0
0 commit comments