diff options
author | Ulrich Drepper <drepper@redhat.com> | 2002-12-30 23:45:39 +0000 |
---|---|---|
committer | Ulrich Drepper <drepper@redhat.com> | 2002-12-30 23:45:39 +0000 |
commit | 49e9f864906640e913ad69f98ce6ee24776d5b8d (patch) | |
tree | 7c5bc877d6564c7d0e1e4230da72061ccf0ad795 /nptl/forward.c | |
parent | f7a0ea26ea79bc86a5fce32551ea0b06a31528fe (diff) | |
download | glibc-49e9f864906640e913ad69f98ce6ee24776d5b8d.tar glibc-49e9f864906640e913ad69f98ce6ee24776d5b8d.tar.gz glibc-49e9f864906640e913ad69f98ce6ee24776d5b8d.tar.bz2 glibc-49e9f864906640e913ad69f98ce6ee24776d5b8d.zip |
Update.
2002-12-30 Jakub Jelinek <jakub@redhat.com>
* forward.c (FORWARD2): Renamed from FORWARD3. Remove unused export
argument.
(pthread_attr_init_2_0, pthread_attr_init_2_1): Use FORWARD macro.
(pthread_exit): Use strong_alias to avoid warnings.
* pthreadP.h (struct pthread_functions): Rename ptr_pthread_exit
and ptr_pthread_attr_init_2_* to ptr___pthread_exit and
ptr___pthread_attr_init_2_*.
* init.c (pthread_functions): Adjust.
Diffstat (limited to 'nptl/forward.c')
-rw-r--r-- | nptl/forward.c | 20 |
1 files changed, 8 insertions, 12 deletions
diff --git a/nptl/forward.c b/nptl/forward.c index 1a73d2ce4b..a167bc1027 100644 --- a/nptl/forward.c +++ b/nptl/forward.c @@ -29,7 +29,7 @@ struct pthread_functions __libc_pthread_functions attribute_hidden; -#define FORWARD3(name, export, rettype, decl, params, defaction) \ +#define FORWARD2(name, rettype, decl, params, defaction) \ rettype \ name decl \ { \ @@ -39,23 +39,18 @@ name decl \ return __libc_pthread_functions.ptr_##name params; \ } -#define FORWARD2(name, decl, params, defretval) \ - FORWARD3 (name, name, int, decl, params, return defretval) - #define FORWARD(name, decl, params, defretval) \ - FORWARD2 (name, decl, params, defretval) + FORWARD2 (name, int, decl, params, return defretval) FORWARD (pthread_attr_destroy, (pthread_attr_t *attr), (attr), 0) #if SHLIB_COMPAT(libc, GLIBC_2_0, GLIBC_2_1) -FORWARD3 (pthread_attr_init_2_0, __pthread_attr_init_2_0, int, - (pthread_attr_t *attr), (attr), return 0) +FORWARD (__pthread_attr_init_2_0, (pthread_attr_t *attr), (attr), 0) compat_symbol (libc, pthread_attr_init_2_0, pthread_attr_init, GLIBC_2_0); #endif -FORWARD3 (pthread_attr_init_2_1, __pthread_attr_init_2_1, int, - (pthread_attr_t *attr), (attr), return 0) +FORWARD (__pthread_attr_init_2_1, (pthread_attr_t *attr), (attr), 0) versioned_symbol (libc, __pthread_attr_init_2_1, pthread_attr_init, GLIBC_2_1); FORWARD (pthread_attr_getdetachstate, @@ -109,8 +104,9 @@ FORWARD (pthread_equal, (pthread_t thread1, pthread_t thread2), (thread1, thread2), 1) -FORWARD3 (pthread_exit, pthread_exit, void, (void *retval), (retval), - exit (EXIT_SUCCESS)) +/* Use an alias to avoid warning, as pthread_exit is declared noreturn. */ +FORWARD2 (__pthread_exit, void, (void *retval), (retval), exit (EXIT_SUCCESS)) +strong_alias (__pthread_exit, pthread_exit); FORWARD (pthread_getschedparam, @@ -132,7 +128,7 @@ FORWARD (pthread_mutex_lock, (pthread_mutex_t *mutex), (mutex), 0) FORWARD (pthread_mutex_unlock, (pthread_mutex_t *mutex), (mutex), 0) -FORWARD3 (pthread_self, pthread_self, pthread_t, (void), (), return 0) +FORWARD2 (pthread_self, pthread_t, (void), (), return 0) FORWARD (pthread_setcancelstate, (int state, int *oldstate), (state, oldstate), |