aboutsummaryrefslogtreecommitdiff
path: root/stdlib
diff options
context:
space:
mode:
authorSamuel Thibault <samuel.thibault@ens-lyon.org>2023-09-04 20:03:37 +0200
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2023-09-04 20:03:37 +0200
commit6333a6014f32c7ced36ced610d5a5cecbafba6c3 (patch)
tree48a3cd9f10e8fb27ee36f76ad25d668bbebcbaac /stdlib
parent2897b231a6b71ee17d47d3d63f1112b2641a476c (diff)
downloadglibc-6333a6014f32c7ced36ced610d5a5cecbafba6c3.zip
glibc-6333a6014f32c7ced36ced610d5a5cecbafba6c3.tar.gz
glibc-6333a6014f32c7ced36ced610d5a5cecbafba6c3.tar.bz2
__call_tls_dtors: Use call_function_static_weak
Diffstat (limited to 'stdlib')
-rw-r--r--stdlib/exit.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/stdlib/exit.c b/stdlib/exit.c
index d6c188b..0cf9bf7 100644
--- a/stdlib/exit.c
+++ b/stdlib/exit.c
@@ -37,11 +37,8 @@ __run_exit_handlers (int status, struct exit_function_list **listp,
bool run_list_atexit, bool run_dtors)
{
/* First, call the TLS destructors. */
-#ifndef SHARED
- if (&__call_tls_dtors != NULL)
-#endif
- if (run_dtors)
- __call_tls_dtors ();
+ if (run_dtors)
+ call_function_static_weak (__call_tls_dtors);
__libc_lock_lock (__exit_funcs_lock);