Skip to content

Reference

std::bad_alloc appearing as STATUS_STACK_BUFFER_OVERRUN

Section titled “std::bad_alloc appearing as STATUS_STACK_BUFFER_OVERRUN”

Cause: Unhandled exception → terminate → abort → /GS check

Solutions:

  1. Prevent it: Use the Build Governor (.\scripts\setup-governor.ps1)
  2. Diagnose it: Use crash handlers to see the real exception

Cause: No PDB files for release builds

Solution: Build with /Zi and /DEBUG linker flag

Cause: Too many parallel compilations exhausting commit charge

Solution: The Build Governor automatically throttles based on memory pressure

FilePurpose
src/crash_handlers.hVerbose crash diagnostics
src/debug_log.hRich-style terminal logging
src/minidump.hAutomatic crash dump capture
src/build_info.hBuild and system info capture
src/rippled_debug.hSingle-include header (all of the above)
tools/build-governor/.NET governor service
scripts/setup-governor.ps1One-command governor setup
scripts/build-rippled.ps1One-command rippled build
patches/rippled_main.patchPatch for Main.cpp
examples/test_crash.cppDemo and test program