Repository navigation
berd-call: start the voice session with posix_spawn - #404
Conversation
The session was spawned with a pre_exec hook, which makes std fork.
Forking the menu bar's multithreaded process can abort the child before
exec ("os_once_t is corrupt" in libnotify's fork handler), and the call
then fails with a broken pipe. Without the hook std uses posix_spawn:
the process group comes from process_group, the audio pipe's read end
is close-on-exec, and the session clears the stop signals the host
blocked.
Signed-off-by: John Tennant <jtennant@block.xyz>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
morgmart
left a comment
There was a problem hiding this comment.
🤖 Automated code review
APPROVE. Fresh static Engineering review of the exact prepared three-dot comparison found no publishable changed-line defects. The project code-review and Wes-review passes found the process-spawn change preserves session startup, signal delivery, process isolation, audio-pipe ownership, cleanup, and failure behavior, with a discriminating regression test for inherited blocked SIGTERM. Supplied GitHub evidence is structurally valid and reports 11 successful checks at the reviewed head SHA; required checks still govern merge readiness. Final self-check covered every changed user flow; accessibility; i18n/localization completeness; navigation and consent guards; async, error, never-completes, lifecycle, and race behavior; test honesty; design-system and project rules; duplicate and overlapping findings; and concrete evidence plus user effect for blocking severity.
Deterministic publication result: 0 blocking and 0 non-blocking inline finding(s) publishable; 0 duplicate(s) suppressed; 0 blocking screenshot-evidence requirement(s) in this review body.
Pending checks: 1 check(s) are not complete.
This approval reflects the completed code review only; merge readiness remains governed by the repository's required checks.
Summary
A Berd Call could fail to start with
could not write voice session input: Broken pipe (os error 32). The voice session process aborted before it ran any Berd Call code: macOS reportedBUG IN CLIENT OF LIBPLATFORM: os_once_t is corrupt, crashed on the child side offorkin libnotify's fork handler. The host spawned the session with apre_exechook, which makes the standard libraryfork. The menu bar's process runs AppKit threads, and if one of them is setting up a system library at that moment, the forked child aborts.The session now starts through
posix_spawn. Without the hook, the standard library uses it, and the hook's work moves to safe places:process_group(0).Related issue
None.
Testing
SIGINTandSIGTERMstill stops onSIGTERM. It failed before the change and passes after.SIGTERMto the host ended both processes.