mirror of
https://github.com/openai/codex.git
synced 2026-10-18 17:18:52 +00:00
## Why Retaining process output, publishing events, and serving reads cloned the underlying byte buffers. Sharing those buffers avoids copying output bytes when chunks are cloned. ## What changed Store `ByteChunk` bytes in `Arc<Vec<u8>>` and retain `ProcessOutputChunk` values directly. Add borrowed byte access for the MCP process transport while preserving base64 serialization and owned byte extraction through `into_inner()`. ## Testing Add a unit test covering base64 serialization, deserialization, and independent owned bytes extracted from shared chunks. GitOrigin-RevId: 6bba114af48424aa844487aa75163cfc604e0575