1
0
mirror of https://sourceware.org/git/glibc.git synced 2025-07-28 00:21:52 +03:00
2002-02-15  Ulrich Drepper  <drepper@redhat.com>

	* elf/dl-open.c (dl_open_worker): Catch wrap-around of TLS
	generation counter.
	* elf/dl-close.c (_dl_close): Likewise.
This commit is contained in:
Ulrich Drepper
2002-02-16 00:21:33 +00:00
parent ebda6173fc
commit b209e34ad6
3 changed files with 12 additions and 2 deletions

View File

@ -21,6 +21,7 @@
#include <dlfcn.h>
#include <errno.h>
#include <libintl.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
@ -431,7 +432,8 @@ dl_open_worker (void *a)
/* Bump the generation number if necessary. */
if (any_tls)
++GL(dl_tls_generation);
if (__builtin_expect (++GL(dl_tls_generation) == 0, 0))
__libc_fatal (gettext ("TLS generation counter wrapped! Please send report with the 'glibcbug' script."));
#endif
/* Run the initializer functions of new objects. */