Commit graph

7 commits

Author SHA1 Message Date
trvon
8911c5fa5e
fix(config): distinguish empty from unset env on Windows
_putenv_s removes a variable for "" and returns EINVAL for NULL, so the
CRT environment cannot represent an explicitly empty value; the boundary
collapsed unset and empty into one state. Read/write through the Win32
environment (SetEnvironmentVariableA/GetEnvironmentVariableA) instead,
keeping a best-effort _putenv_s sync so legacy std::getenv readers stay
coherent, and treat the empty-vs-unset read race fail-closed.
2026-08-12 19:14:34 -06:00
trvon
03aed28eda
fix(config): stack daemon environment leases 2026-08-05 20:53:19 -04:00
trvon
30618eb113
refactor(config): consolidate runtime tuning 2026-08-05 20:53:18 -04:00
trvon
e85339ac30
refactor(config): unify flat TOML lookups 2026-08-05 20:53:17 -04:00
trvon
5066fc0893
test: isolate process environment 2026-08-04 21:31:39 -04:00
trvon
34a799d10e
refactor(config): unify environment policy 2026-08-04 14:35:10 -04:00
trvon
25bce22f15
fix(build): restore MSVC and Apple libc++ portability
- replace GCC/Clang-only __builtin_{add,sub,mul}_overflow calls with
  yams/core/checked_arithmetic.h helpers (addOverflow/subOverflow/
  mulOverflow/narrowOverflow); MSVC lacks these builtins, breaking the
  Windows build introduced by #61
- port the reviewed helper + unit tests from bugfix/review-findings
- detect floating-point std::from_chars availability at compile time
  (some Apple libc++ versions only provide the integral overload) and
  fall back to a strict strtod parser; template indirection keeps the
  missing overload from being diagnosed in the discarded branch
- add config_parse_utils and checked_arithmetic test targets
2026-07-31 16:40:15 -04:00