Handle forwarding failures gracefully

This commit is contained in:
Marcin Kulik
2025-04-04 21:04:24 +02:00
parent fa3d6cdb12
commit 1226cacff3

View File

@@ -172,17 +172,13 @@ impl session::Output for Output {
) -> io::Result<()> {
self.0
.send(Message::Start(tty_size, theme))
.expect("send should succeed");
Ok(())
.map_err(io::Error::other)
}
fn event(&mut self, event: session::Event) -> io::Result<()> {
self.0
.send(Message::SessionEvent(event))
.expect("send should succeed");
Ok(())
.map_err(io::Error::other)
}
fn flush(&mut self) -> io::Result<()> {