Skip to content

Commit 0836f08

Browse files
address CR
1 parent 175ae9a commit 0836f08

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

libc/src/stdlib/CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -631,6 +631,7 @@ add_entrypoint_object(
631631
HDRS
632632
exit.h
633633
DEPENDS
634+
libc.src.__support.threads.thread
634635
${exit_deps}
635636
)
636637

libc/src/stdlib/exit.cpp

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,11 @@
1414
namespace LIBC_NAMESPACE_DECL {
1515

1616
extern "C" void __cxa_finalize(void *);
17-
extern "C" [[gnu::weak]] void __cxa_thread_finalize();
17+
extern "C" void __cxa_thread_finalize();
1818

1919
// TODO: use recursive mutex to protect this routine.
2020
[[noreturn]] LLVM_LIBC_FUNCTION(void, exit, (int status)) {
21-
if (__cxa_thread_finalize)
22-
__cxa_thread_finalize();
21+
__cxa_thread_finalize();
2322
__cxa_finalize(nullptr);
2423
internal::exit(status);
2524
}

0 commit comments

Comments
 (0)