diff options
Diffstat (limited to 'linuxthreads')
-rw-r--r-- | linuxthreads/ChangeLog | 6 | ||||
-rw-r--r-- | linuxthreads/sysdeps/pthread/timer_routines.c | 8 |
2 files changed, 9 insertions, 5 deletions
diff --git a/linuxthreads/ChangeLog b/linuxthreads/ChangeLog index 0d3f95c1bb..434e7c7182 100644 --- a/linuxthreads/ChangeLog +++ b/linuxthreads/ChangeLog @@ -1,3 +1,9 @@ +2002-08-28 Ulrich Drepper <drepper@redhat.com> + + * sysdeps/pthread/timer_routines.c (thread_func): Change return + type to void and add casts in use to avoid warnings wit all gcc + versions. + 2002-08-08 Jakub Jelinek <jakub@redhat.com> * sysdeps/unix/sysv/linux/bits/local_lim.h (PTHREAD_THREADS_MAX): diff --git a/linuxthreads/sysdeps/pthread/timer_routines.c b/linuxthreads/sysdeps/pthread/timer_routines.c index 110448c769..86fae2af4c 100644 --- a/linuxthreads/sysdeps/pthread/timer_routines.c +++ b/linuxthreads/sysdeps/pthread/timer_routines.c @@ -369,7 +369,7 @@ thread_expire_timer (struct thread_node *self, struct timer_node *timer) function is to wait on the thread's timer queue and expire the timers in chronological order as close to their scheduled time as possible. */ -static void * +static void __attribute__ ((noreturn)) thread_func (void *arg) { @@ -449,9 +449,6 @@ thread_func (void *arg) /* This macro will never be executed since the while loop loops forever - but we have to add it for proper nesting. */ pthread_cleanup_pop (1); - - /* NOTREACHED */ - return NULL; } @@ -492,7 +489,8 @@ __timer_thread_start (struct thread_node *thread) assert (!thread->exists); thread->exists = 1; - if (pthread_create (&thread->id, &thread->attr, thread_func, thread) != 0) + if (pthread_create (&thread->id, &thread->attr, + (void (*) (void *)) thread_func, thread) != 0) { thread->exists = 0; retval = -1; |