From e7d8220788b4fa7c266a1e4457591b694478771c Mon Sep 17 00:00:00 2001 From: Can Celik Date: Mon, 7 Sep 2026 16:14:46 +0300 Subject: fix: preserve sessions after interrupted pane exits (#3418) * fix: preserve sessions when pane shells are signaled refs #3415 * fix: preserve shutdown checkpoints across platforms refs #3415 --------- Co-authored-by: Jonathan Liebig --- src/platform/unix_common.rs | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src/platform/unix_common.rs') diff --git a/src/platform/unix_common.rs b/src/platform/unix_common.rs index dff67357..104f6b69 100644 --- a/src/platform/unix_common.rs +++ b/src/platform/unix_common.rs @@ -1,5 +1,13 @@ use std::path::{Path, PathBuf}; +pub(crate) fn classify_child_exit(status: &portable_pty::ExitStatus) -> super::ChildExitReason { + if status.signal().is_some() { + super::ChildExitReason::Interrupted + } else { + super::ChildExitReason::Exited + } +} + pub(crate) fn wait_client_stream_readable(stream: &crate::ipc::LocalStream) -> std::io::Result<()> { use std::os::fd::{AsFd as _, AsRawFd as _}; let crate::ipc::LocalStream::UdSocket(stream) = stream; -- cgit v1.2.3