1
0
mirror of https://sourceware.org/git/glibc.git synced 2025-09-11 12:10:50 +03:00
This commit is contained in:
Jakub Jelinek
2007-07-31 13:33:18 +00:00
parent d6220e9ee3
commit 32c075e1f0
448 changed files with 13841 additions and 10982 deletions

View File

@@ -104,6 +104,10 @@ CFLAGS-strfmon.c = -D_IO_MTSAFE_IO
CFLAGS-strfmon_l.c = -D_IO_MTSAFE_IO
endif
ifeq (yes,$(have-protected))
CFLAGS-atexit.c = -DHAVE_DOT_HIDDEN
endif
CFLAGS-tst-bsearch.c = $(stack-align-test-flags)
CFLAGS-tst-qsort.c = $(stack-align-test-flags)

View File

@@ -1,4 +1,4 @@
/* Copyright (C) 1991, 1996, 1999, 2001, 2006 Free Software Foundation, Inc.
/* Copyright (C) 1991, 1996, 1999, 2001 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -43,11 +43,14 @@ extern void *__dso_handle __attribute__ ((__weak__));
/* Register FUNC to be executed by `exit'. */
int
#ifndef atexit
attribute_hidden
#endif
atexit (void (*func) (void))
{
return __cxa_atexit ((void (*) (void *)) func, NULL,
&__dso_handle == NULL ? NULL : __dso_handle);
}
/* Hide the symbol so that no definition but the one locally in the
executable or DSO is used. */
#ifdef HAVE_DOT_HIDDEN
asm (".hidden\tatexit");
#endif

View File

@@ -45,8 +45,8 @@ __cxa_finalize (void *d)
/* We don't want to run this cleanup more than once. */
&& (cxafn = f->func.cxa.fn,
cxaarg = f->func.cxa.arg,
! catomic_compare_and_exchange_bool_acq (&f->flavor, ef_free,
ef_cxa)))
! atomic_compare_and_exchange_bool_acq (&f->flavor, ef_free,
ef_cxa)))
{
uint64_t check = __new_exitfn_called;

View File

@@ -1,4 +1,4 @@
/* Copyright (C) 1991-2003,2004,2005,2006 Free Software Foundation, Inc.
/* Copyright (C) 1991-2003,2004,2005,2006,2007 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -741,18 +741,18 @@ __END_NAMESPACE_STD
#ifdef __USE_GNU
/* Return a malloc'd string containing the canonical absolute name of the
existing named file. */
named file. The last file name component need not exist, and may be a
symlink to a nonexistent file. */
extern char *canonicalize_file_name (__const char *__name)
__THROW __nonnull ((1)) __wur;
#endif
#if defined __USE_BSD || defined __USE_XOPEN_EXTENDED
/* Return the canonical absolute name of file NAME. The last file name
component need not exist, and may be a symlink to a nonexistent file.
If RESOLVED is null, the result is malloc'd; otherwise, if the canonical
name is PATH_MAX chars or more, returns null with `errno' set to
ENAMETOOLONG; if the name fits in fewer than PATH_MAX chars, returns the
name in RESOLVED. */
/* Return the canonical absolute name of file NAME. If RESOLVED is
null, the result is malloc'd; otherwise, if the canonical name is
PATH_MAX chars or more, returns null with `errno' set to
ENAMETOOLONG; if the name fits in fewer than PATH_MAX chars,
returns the name in RESOLVED. */
extern char *realpath (__const char *__restrict __name,
char *__restrict __resolved) __THROW __wur;
#endif