This is the mail archive of the
libc-alpha@sources.redhat.com
mailing list for the glibc project.
Fix errno on Alpha
- From: Daniel Jacobowitz <drow at mvista dot com>
- To: libc-alpha at sources dot redhat dot com
- Date: Wed, 8 Jan 2003 10:30:12 -0500
- Subject: Fix errno on Alpha
Right now, Alpha uses a !samegp optimized branch to call
__errno_location. This tells the linker that we always want the copy
of __errno_location in this shared object; so syscalls never find the
copy in libpthread.so, and set the main thread's errno instead of the
current thread's errno. Easily fixed, like so; please apply.
--
Daniel Jacobowitz
MontaVista Software Debian GNU/Linux Developer
2003-01-08 Daniel Jacobowitz <drow@mvista.com>
* sysdeps/unix/alpha/sysdep.S (__syscall_error): Don't use
!samegp to call __errno_location.
--- sysdeps/unix/alpha/sysdep.S 2002-12-23 10:47:40.000000000 -0500
+++ sysdeps/unix/alpha/sysdep.S 2003-01-07 23:04:21.000000000 -0500
@@ -68,11 +68,7 @@
PROLOGUE
/* Find our per-thread errno address */
-#ifdef PIC
- bsr ra, __errno_location !samegp
-#else
jsr ra, __errno_location
-#endif
/* Store the error value. */
ldq t0, 8(sp)