This is the mail archive of the libc-hacker@sources.redhat.com mailing list for the glibc project.
Note that libc-hacker is a closed list. You may look at the archives of this list, but subscription and posting are not open.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
Other format: | [Raw text] |
Hi! 2004-03-22 Jakub Jelinek <jakub@redhat.com> * sysdeps/unix/sysv/linux/sparc/sparc32/getpagesize.c (__getpagesize): Avoid warning about writing into read-only memory. --- libc/sysdeps/unix/sysv/linux/sparc/sparc32/getpagesize.c.jj 2004-03-06 03:07:13.000000000 -0500 +++ libc/sysdeps/unix/sysv/linux/sparc/sparc32/getpagesize.c 2004-03-22 18:06:44.000000000 -0500 @@ -31,12 +31,16 @@ int __getpagesize () { - if (GLRO(dl_pagesize) == 0) + int ret = GLRO(dl_pagesize); + if (ret == 0) { INTERNAL_SYSCALL_DECL (err); - GLRO(dl_pagesize) = INTERNAL_SYSCALL (getpagesize, err, 0); + ret = INTERNAL_SYSCALL (getpagesize, err, 0); +#ifndef SHARED + GLRO(dl_pagesize) = ret; +#endif } - return GLRO(dl_pagesize); + return ret; } libc_hidden_def (__getpagesize) weak_alias (__getpagesize, getpagesize) Jakub
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |