sshpeer: fix another occurrence of short write handling stable
authorArseniy Alekseyev <aalekseyev@janestreet.com>
Thu, 06 Feb 2025 15:37:59 +0000
branchstable
changeset 52967 f6b30f4b5e07
parent 52966 7aec18bded6d
child 52985 b964f92261d4
sshpeer: fix another occurrence of short write handling This one is much less likely to be problematic in practice since the data we're writing is constant-size, but it's not enough to completely rule out the problem.
mercurial/sshpeer.py
--- a/mercurial/sshpeer.py	Wed Feb 05 16:49:43 2025 +0000
+++ b/mercurial/sshpeer.py	Thu Feb 06 15:37:59 2025 +0000
@@ -342,7 +342,7 @@
         ui.debug(b'sending hello command\n')
         ui.debug(b'sending between command\n')
 
-        stdin.write(b''.join(handshake))
+        _write_all(stdin.write, b''.join(handshake))
         stdin.flush()
     except IOError:
         badresponse()