mirror of
https://github.com/openai/codex.git
synced 2026-09-10 20:26:47 +00:00
## What Fix bash command parsing to accept double-quoted strings that contain literal newlines so execpolicy can match allow rules. ## Why Allow rules like [git, commit] should still match when commit messages include a newline in a quoted argument; the parser currently rejects these strings and falls back to the outer shell invocation. ## How - Validate double-quoted strings by ensuring all named children are string_content and then stripping the outer quotes from the raw node text so embedded newlines are preserved. - Reuse the helper for concatenated arguments. - Ensure large SI suffix formatting uses the caller-provided locale formatter for grouping. - Add coverage for newline-containing quoted arguments. Fixes #9541. ## Tests - cargo test -p codex-core - just fix -p codex-core - cargo test -p codex-protocol - just fix -p codex-protocol - cargo test --all-features