about summary refs log tree commit diff
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2002-08-20 00:23:31 +0000
committerUlrich Drepper <drepper@redhat.com>2002-08-20 00:23:31 +0000
commitb68364367b89e3348c09a48eb7f222b4b70d269c (patch)
tree5e322b87678aaa21b5903040e6256df161e0f66e
parent46615777f5cef0d0ade26ac3978b7f2ed5a1cea2 (diff)
downloadglibc-b68364367b89e3348c09a48eb7f222b4b70d269c.tar.gz
glibc-b68364367b89e3348c09a48eb7f222b4b70d269c.tar.xz
glibc-b68364367b89e3348c09a48eb7f222b4b70d269c.zip
Update.
2002-08-19  Ulrich Drepper  <drepper@redhat.com>

	* sysdeps/generic/dl-tls.c (_dl_allocate_tls_init): Return
	immediately if result == NULL.

	* locale/loadarchive.c (_nl_load_locale_from_archive): Braino fix
-rw-r--r--ChangeLog7
-rw-r--r--sysdeps/generic/dl-tls.c8
2 files changed, 13 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index b24f870f02..21164f2ff5 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2002-08-19  Ulrich Drepper  <drepper@redhat.com>
+
+	* sysdeps/generic/dl-tls.c (_dl_allocate_tls_init): Return
+	immediately if result == NULL.
+
 2002-08-16  Jakub Jelinek  <jakub@redhat.com>
 
 	* sysdeps/alpha/fpu/libm-test-ulps: Regenerate.
@@ -14,7 +19,7 @@
 
 2002-08-16  Jakub Jelinek  <jakub@redhat.com>
 
-        * locale/loadarchive.c (_nl_load_locale_from_archive): Braino fix
+	* locale/loadarchive.c (_nl_load_locale_from_archive): Braino fix
 	in change before last: MAX -> MIN.
 
 2002-08-15  Roland McGrath  <roland@redhat.com>
diff --git a/sysdeps/generic/dl-tls.c b/sysdeps/generic/dl-tls.c
index cb46460d25..2b47195c96 100644
--- a/sysdeps/generic/dl-tls.c
+++ b/sysdeps/generic/dl-tls.c
@@ -240,7 +240,7 @@ _dl_allocate_tls_storage (void)
 
   return result;
 }
-INTDEF(_dl_allocate_tls)
+
 
 void *
 internal_function
@@ -250,6 +250,10 @@ _dl_allocate_tls_init (void *result)
   struct dtv_slotinfo_list *listp;
   size_t total = 0;
 
+  if (result == NULL)
+    /* The memory allocation failed.  */
+    return NULL;
+
   /* We have to look prepare the dtv for all currently loaded
      modules using TLS.  For those which are dynamically loaded we
      add the values indicating deferred allocation.  */
@@ -315,6 +319,8 @@ _dl_allocate_tls (void)
 {
   return _dl_allocate_tls_init (_dl_allocate_tls_storage ());
 }
+INTDEF(_dl_allocate_tls)
+
 
 void
 internal_function