Compare commits

...

2 Commits

Author SHA1 Message Date
will.anderson 93d36fddb1 fix(windows): guard el_mem_check with _WIN32 — rusage is POSIX-only
El SDK CI - stage / build-and-test (pull_request) Failing after 11m3s
2026-06-25 11:45:36 -05:00
will.anderson 2d751890ea feat(windows): native Windows port of el_runtime.c — fix all blockers
El SDK CI - stage / build-and-test (push) Failing after 7m45s
2026-06-20 00:06:04 +00:00
+5
View File
@@ -5880,6 +5880,10 @@ el_val_t getpid_now(void) {
* Returns 0 always (the only non-return path is the exit() branch).
*/
el_val_t el_mem_check(void) {
#ifdef _WIN32
/* getrusage is POSIX-only — memory guard disabled on Windows. */
return 0;
#else
/* Read limit from env; default 512 MB. */
long limit_mb = 512;
const char *env_val = getenv("ELC_MAX_MEM_MB");
@@ -5905,6 +5909,7 @@ el_val_t el_mem_check(void) {
exit(1);
}
return 0;
#endif
}
/* ── args() — command-line argument access ──────────────────────────────────