Files
proxypin/lib/network/util
testercengdong d69b95dbbc fix(macos,process_info): tighten error handling and add endian assert
- Guard against `getProcess` returning null in the macOS FFI path
  (`proc_pidpath` can fail with EPERM or for an already-exited PID).
  Stop unwrapping with `!` and only populate the ProcessInfoCache on
  success; the previous code threw NullThrownError there, which the
  outer try/catch silently swallowed and prevented caching of valid
  later results.
- Add a 5-second negative cache for ports whose owner can't be
  resolved (typical for short-lived clients that exited before we
  scanned). Without it every such request triggered a full PID list
  rescan, defeating the point of the pid cache for the failure path.
- Add a debug-only assert that the host is little-endian. The libproc
  parsing reads `(int)htons(port)` by treating the low two bytes as a
  big-endian uint16, which requires a little-endian host. All shipping
  macOS hardware satisfies this; the assert fails loudly if the
  assumption is ever broken (stripped from release builds).

Re-verified on macOS 26.4: 500 concurrent curl through the proxy,
single ProxyPin process throughout, 9099 freed immediately on exit.
2026-05-12 10:16:42 +08:00
..
2025-01-15 01:36:00 +08:00
2025-05-07 14:50:55 +08:00
2024-10-29 01:31:50 +08:00
2024-10-29 01:31:50 +08:00
2025-05-31 03:57:58 +08:00
2024-02-24 22:18:18 +08:00
2024-11-12 09:29:15 +08:00