From e1952d35e694904abb08dafc516c4be838dc9ca5 Mon Sep 17 00:00:00 2001 From: MoerAI Date: Wed, 4 Mar 2026 12:24:22 +0900 Subject: [PATCH] fix(tmux): handle \r line endings and missing pane_title in list-panes Strip \r characters from list-panes output to handle Windows-style line endings. Also relax field count check from 9 to 8 to handle cases where pane_title is empty or missing, which caused the parser to drop pane rows and fail to determine the main pane in single-pane sessions. Fixes #2241 --- src/features/tmux-subagent/pane-state-querier.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/features/tmux-subagent/pane-state-querier.ts b/src/features/tmux-subagent/pane-state-querier.ts index 28d5158a44..2c581163dd 100644 --- a/src/features/tmux-subagent/pane-state-querier.ts +++ b/src/features/tmux-subagent/pane-state-querier.ts @@ -27,7 +27,7 @@ export async function queryWindowState(sourcePaneId: string): Promise 8 ? fields.slice(8).join("\t") : "" const width = parseInt(widthStr, 10) const height = parseInt(heightStr, 10) const left = parseInt(leftStr, 10)