From 0b53da18d579606c75562e4334a96ac0fcdcc590 Mon Sep 17 00:00:00 2001 From: Lukas Wirth Date: Thu, 6 Nov 2025 15:27:26 +0100 Subject: [PATCH] remote: Flush to stdin when writing to sftp (#42103) https://github.com/zed-industries/zed/issues/42027#issuecomment-3497210172 Release Notes: - Fixed ssh remoting potentially failing due to not flushing stdin to sftp --- crates/remote/src/transport/ssh.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/remote/src/transport/ssh.rs b/crates/remote/src/transport/ssh.rs index db6a1971a7bc43471fe71c25d571c0a53f81bd72..a8e4245b4352ec06ff285d772550993172173d78 100644 --- a/crates/remote/src/transport/ssh.rs +++ b/crates/remote/src/transport/ssh.rs @@ -867,7 +867,7 @@ impl SshRemoteConnection { if let Some(mut stdin) = child.stdin.take() { use futures::AsyncWriteExt; stdin.write_all(sftp_batch.as_bytes()).await?; - drop(stdin); + stdin.flush().await?; } let output = child.output().await?;