This is the mail archive of the
libc-alpha@sources.redhat.com
mailing list for the glibc project.
PATCH: Fix binary compatibility loss regarding errno
- From: "H. J. Lu" <hjl at lucon dot org>
- To: libc-alpha at sources dot redhat dot com
- Date: Mon, 30 Dec 2002 10:51:11 -0800
- Subject: PATCH: Fix binary compatibility loss regarding errno
Here is a patch for errno. I don't know if there are any other similar
issuses.
H.J.
----
2002-12-30 H.J. Lu <hjl@gnu.org>
* sysdeps/generic/errno.c (errno): Fix GLIBC_2_0 version.
(_errno): Likewise.
--- sysdeps/generic/errno.c.errno Fri Nov 22 10:22:46 2002
+++ sysdeps/generic/errno.c Mon Dec 30 10:46:57 2002
@@ -29,14 +29,14 @@ extern __thread int __libc_errno __attri
/* This differs from plain `int errno;' in that it doesn't create
a common definition, but a plain symbol that resides in .bss,
which can have an alias. */
-int errno __attribute__ ((section (".bss")));
-strong_alias (errno, _errno)
+int __old_errno __attribute__ ((section (".bss")));
+strong_alias (__old_errno, ___old_errno)
/* We declare these with compat_symbol so that they are not
visible at link time. Programs must use the accessor functions. */
# if defined HAVE_ELF && defined SHARED && defined DO_VERSIONING
# include <shlib-compat.h>
-compat_symbol (libc, errno, errno, GLIBC_2_0);
-compat_symbol (libc, _errno, _errno, GLIBC_2_0);
+compat_symbol (libc, __old_errno, errno, GLIBC_2_0);
+compat_symbol (libc, ___old_errno, _errno, GLIBC_2_0);
# endif
#endif