Repository navigation
Windows: codex-cli 0.154.0 fatal memory allocation failure (1366784 bytes), event 0xc0000409 #46201
Description
Summary
Codex on Windows terminated during an active, long-running agent session after displaying:
memory allocation of 1366784 bytes failed
Windows Application Error independently records a crash of codex.exe at 2026-09-17T12:07:50.446Z, exception 0xc0000409. Root cause is unknown; this report does not establish a leak, global memory exhaustion, or a specific tool as the cause.
Environment
- Windows 11 Pro x64, version
10.0.26200. - Approximately 32 GB installed RAM (OS-visible 32,324,024 KiB).
- Running the executable identified in the event with
--versionreturnscodex-cli 0.154.0. - Sanitized executable path:
%LOCALAPPDATA%\Programs\OpenAI\Codex\bin\codex.exe. - An installed Store package reports
OpenAI.Codex 26.908.9136.0; this is included as installation metadata, not proof that this exact UI package was the faulting process.
Activity and observed behavior
- A long conversation had used independent subagents, local file reads/writes, document-extraction trials, and MCP tools.
- The agent was recording an approved plan through an external task-management MCP, persisting an idempotency checkpoint between operations.
- The user saw the allocator error above and Codex closed. An in-progress orchestration/tool call was aborted.
- After restarting, local artifacts and the last checkpoint were still present. Read-back from the external system showed that one task creation had committed and subsequent intended creations had not. Recovery required reconciling that partial completion before resuming.
This is a reported single occurrence; no minimal reproducer or memory-growth profile is available. We did not intentionally reproduce the crash.
Sanitized Windows event evidence
Event ID: 1000
Provider: Application Error
Faulting application: codex.exe
Faulting module: codex.exe
Application/module version: 0.0.0.0
Timestamp: 0x6aa1dbcf
Exception code: 0xc0000409
Fault offset: 0x000000000ceece81
Event time UTC: 2026-09-17T12:07:50.446Z
Related WER Event ID: 1001
Event Name: BEX64
P8: c0000409
P9: 0000000000000007
A measurement after restarting showed roughly 17 GB free physical memory and 20 GB free virtual memory. This is not memory telemetry from the time of the crash and cannot rule out earlier memory pressure.
Expected behavior
The session should remain running or recover with a clear error. A fatal backend termination during an external mutation should preserve/recover the state and make the uncertain completion boundary visible.
Additional context
Searched existing issues for the exact allocation size and Windows allocation errors. Related memory reports exist, but we have not established that they share this cause. No project documents, credentials, raw conversations, or memory dumps are attached.
Activity