diff options
author | Thomas Weißschuh <thomas.weissschuh@linutronix.de> | 2025-04-11 11:00:43 +0200 |
---|---|---|
committer | Thomas Weißschuh <linux@weissschuh.net> | 2025-04-22 10:56:27 +0200 |
commit | 7b11531ed172cc8cc2465e99c295af5ac2fd55e3 (patch) | |
tree | 5111694e67b705d2a09f91401ac7cdd8c86cf9d1 | |
parent | 9b070d97d9e52195c3a2ee084fdd7c45b6b35adf (diff) |
tools/nolibc: add _exit()
_exit() is the faster variant of exit(), skipping all cleanup actions.
As nolibc does not perform any cleanup anyways, the implementation is
trivial.
Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de>
Acked-by: Willy Tarreau <w@1wt.eu>
-rw-r--r-- | tools/include/nolibc/sys.h | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/tools/include/nolibc/sys.h b/tools/include/nolibc/sys.h index aa0d0871b251..6fe288237020 100644 --- a/tools/include/nolibc/sys.h +++ b/tools/include/nolibc/sys.h @@ -300,11 +300,17 @@ void sys_exit(int status) } static __attribute__((noreturn,unused)) -void exit(int status) +void _exit(int status) { sys_exit(status); } +static __attribute__((noreturn,unused)) +void exit(int status) +{ + _exit(status); +} + /* * pid_t fork(void); |