[BUG] Bun Bun Segmentation Fault Crashes on Windows

Open 💬 7 comments Opened Jan 28, 2026 by BrainMode

Preflight Checklist

  • [x] I have searched existing issues and this hasn't been reported yet
  • [x] This is a single bug report (please file separate reports for different bugs)
  • [x] I am using the latest version of Claude Code

What's Wrong?

Claude Code crashes with Bun segmentation faults during normal usage on Windows 11. The crashes occur randomly - both after long sessions (2.5h) and short ones (~5 min). The embedded Bun runtime panics with "Segmentation fault at address 0xFFFFFFFFFFFFFFFF".

What Should Happen?

Claude Code should run stably without crashing. The embedded Bun runtime should handle memory management correctly regardless of session length.

Error Messages/Logs

Crash 1 (Long Session):
Bun v1.3.5 (1e86cebd) Windows x64 (baseline)
Windows v.win11_dt
CPU: sse42 avx avx2
Args: "claude" "--dangerously-skip-permissions"
Elapsed: 9249755ms | User: 303828ms | Sys: 49078ms
RSS: 1.95GB | Peak: 1.96GB | Commit: 2.42GB | Faults: 20484449
panic(main thread): Segmentation fault at address 0xFFFFFFFFFFFFFFFE
https://bun.report/1.3.5/e_11e86cebmgEuhogC44s/wB84pi3B_________________A2DF


Crash 2 (Short Session):
Bun v1.3.5 (1e86cebd) Windows x64 (baseline)
Windows v.win11_dt
CPU: sse42 avx avx2
Args: "claude" "--dangerously-skip-permissions"
Elapsed: 284321ms | User: 46750ms | Sys: 8000ms
RSS: 1.32GB | Peak: 1.53GB | Commit: 1.60GB | Faults: 2464280
panic(main thread): Segmentation fault at address 0xFFFFFFFFFFFFFFFF
https://bun.report/1.3.5/e_11e86cebmgEuhogC4r0zmB+qrzxB20qyxB___A2DD

Steps to Reproduce

  1. Open CMD on Windows 11
  2. Navigate to a project folder: cd /d "E:\Claude Code Projekte\*****"
  3. Start Claude Code: claude --dangerously-skip-permissions
  4. Work on tasks (coding, file editing, running commands)
  5. After some time (5 min to 2+ hours), Claude Code crashes with segmentation fault

Note: The crash is not deterministic and happens randomly during normal tool usage.

Claude Model

Opus

Is this a regression?

I don't know

Last Working Version

_No response_

Claude Code Version

2.1.22

Platform

Anthropic API

Operating System

Windows

Terminal/Shell

Windows Terminal

Additional Information

  • Both crashes show invalid memory addresses (0xFFFFFFFFFFFFFFFE / 0xFFFFFFFFFFFFFFFF)
  • Memory usage is high before crash (1.3-2GB RSS)
  • First crash occurred when context was at 7% (possibly during auto-compact)
  • Second crash occurred in a fresh session after only ~5 minutes
  • Using --dangerously-skip-permissions flag
  • Project type: TypeScript/React

View original on GitHub ↗

This issue has 7 comments on GitHub. Read the full discussion on GitHub ↗