about summary refs log tree commit diff
path: root/locale
diff options
context:
space:
mode:
Diffstat (limited to 'locale')
-rw-r--r--locale/loadarchive.c2
-rw-r--r--locale/setlocale.c4
2 files changed, 2 insertions, 4 deletions
diff --git a/locale/loadarchive.c b/locale/loadarchive.c
index aa19dbd5f8..dbb4d7afd5 100644
--- a/locale/loadarchive.c
+++ b/locale/loadarchive.c
@@ -493,7 +493,7 @@ _nl_load_locale_from_archive (int category, const char **namep)
   return lia->data[category];
 }
 
-void
+void __libc_freeres_fn_section
 _nl_archive_subfreeres (void)
 {
   struct locale_in_archive *lia;
diff --git a/locale/setlocale.c b/locale/setlocale.c
index 56a875e378..50c752826c 100644
--- a/locale/setlocale.c
+++ b/locale/setlocale.c
@@ -463,8 +463,7 @@ free_category (int category,
     }
 }
 
-static void __attribute__ ((unused))
-free_mem (void)
+libc_freeres_fn (free_mem)
 {
 #ifdef NL_CURRENT_INDIRECT
   /* We don't use the loop because we want to have individual weak
@@ -494,4 +493,3 @@ free_mem (void)
      not called _nl_unload_locale on them above.  */
   _nl_archive_subfreeres ();
 }
-text_set_element (__libc_subfreeres, free_mem);