harden PTY FFI layer for macOS

Platform-dispatched constants where Linux and macOS diverge:
TIOCSWINSZ, O_NONBLOCK, MsghdrDarwin struct (4-byte msg_iovlen
and msg_controllen vs Linux's 8-byte size_t fields), and split
recvmsg into Linux/Darwin typed variants so scm_rights uses the
correct struct per platform.

Also: app settings dir uses ~/Library/Application Support on
macOS, removed hardcoded TERMINFO from pane spawn env, removed
debug print from native_pty resize.

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
2026-05-03 21:52:13 +02:00
co-authored by Claude
parent 9c7ec008dc
commit 943ab966d2
6 changed files with 141 additions and 101 deletions
-1
View File
@@ -56,7 +56,6 @@ class PaneRegistry {
'COLORTERM': 'truecolor',
'LANG': 'en_US.UTF-8',
'LC_ALL': 'en_US.UTF-8',
'TERMINFO': '/usr/share/terminfo',
if (env != null) ...env,
};