From 83dd1777618ba768de4e0e23202ff2af1678163e Mon Sep 17 00:00:00 2001 From: Konstantin Belousov Date: Sat, 24 Mar 2012 19:13:10 +0000 Subject: [PATCH] Provide short-circuit exit(3) implementation for rtld. There is no atexit finalizers in rtld to call on rtld exiting (due to errors). Submitted by: bde No objections from: kan MFC after: 2 weeks --- libexec/rtld-elf/rtld.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/libexec/rtld-elf/rtld.c b/libexec/rtld-elf/rtld.c index 4dac1c12554e..b3d3329366d8 100644 --- a/libexec/rtld-elf/rtld.c +++ b/libexec/rtld-elf/rtld.c @@ -4364,6 +4364,17 @@ __getosreldate(void) return (osreldate); } +void +exit(int status) +{ + + _exit(status); +} + +void (*__cleanup)(void); +int __isthreaded = 0; +int _thread_autoinit_dummy_decl = 1; + /* * No unresolved symbols for rtld. */