fix(cli): send rides the one-shot SendInput instead of a preempting attach

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014JPaaZVK7rfQPKyrymzsYv
This commit is contained in:
thomas
2026-07-31 11:05:15 +08:00
co-authored by Claude Fable 5
parent b047b4cc06
commit 05dffdf1f4
+3 -6
View File
@@ -158,12 +158,9 @@ impl Backend for RealBackend {
}
fn send_input(&mut self, pane: u64, bytes: Vec<u8>) -> Result<()> {
let mut session = self
.pane_client()?
.attach(pane, SESSION_SIZE)
.with_context(|| format!("attaching to pane %{pane}"))?;
session.input(&bytes)?;
session.detach()?;
self.pane_client()?
.send_input(pane, &bytes)
.with_context(|| format!("sending input to pane %{pane}"))?;
Ok(())
}