From 69e6fe89fa9baafeca3e3515bb50897cd8ee7c35 Mon Sep 17 00:00:00 2001 From: Kacper Date: Mon, 15 Dec 2025 18:24:54 +0100 Subject: Add getauxval and cleanup libc startup --- lib/libc/stdlib/getenv.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'lib/libc/stdlib/getenv.c') diff --git a/lib/libc/stdlib/getenv.c b/lib/libc/stdlib/getenv.c index 41517e2f..91cdc87b 100644 --- a/lib/libc/stdlib/getenv.c +++ b/lib/libc/stdlib/getenv.c @@ -7,7 +7,7 @@ extern char **environ; char *getenv(const char *name) { - LIBC_LOCK(libc.lock.environ); + LIBC_LOCK(__libc.lock.environ); for (char **env = environ; *env; env++) { char *eq = NULL; @@ -21,12 +21,12 @@ char *getenv(const char *name) } } if (eq && name[eq - *env] == '\0') { - LIBC_UNLOCK(libc.lock.environ); + LIBC_UNLOCK(__libc.lock.environ); return eq + 1; } } - LIBC_UNLOCK(libc.lock.environ); + LIBC_UNLOCK(__libc.lock.environ); return NULL; } -- cgit v1.2.3