From f521be31b96b5ca8b6d24c388d644f5dfcafac7d Mon Sep 17 00:00:00 2001 From: Ulrich Drepper Date: Sun, 26 Apr 2009 18:06:47 +0000 Subject: * sysdeps/unix/sysv/linux/libc_pthread_init.c (__libc_pthread_init): Avoid warning by using may_alias attribute on ptrhack. --- nptl/sysdeps/unix/sysv/linux/libc_pthread_init.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'nptl/sysdeps/unix') diff --git a/nptl/sysdeps/unix/sysv/linux/libc_pthread_init.c b/nptl/sysdeps/unix/sysv/linux/libc_pthread_init.c index 4b614bd1a6..8924c4f450 100644 --- a/nptl/sysdeps/unix/sysv/linux/libc_pthread_init.c +++ b/nptl/sysdeps/unix/sysv/linux/libc_pthread_init.c @@ -1,4 +1,4 @@ -/* Copyright (C) 2002, 2003, 2005, 2006, 2007 Free Software Foundation, Inc. +/* Copyright (C) 2002,2003,2005,2006,2007,2009 Free Software Foundation, Inc. This file is part of the GNU C Library. Contributed by Ulrich Drepper , 2002. @@ -56,10 +56,10 @@ __libc_pthread_init (ptr, reclaim, functions) union ptrhack { struct pthread_functions pf; - void *parr[1]; - } const *src; - union ptrhack *dest; # define NPTRS (sizeof (struct pthread_functions) / sizeof (void *)) + void *parr[NPTRS]; + } __attribute__ ((may_alias)) const *src; + union ptrhack *dest; src = (const void *) functions; dest = (void *) &__libc_pthread_functions; -- cgit v1.2.3-70-g09d2