From 7a9ce79a3b0746e0db7d3cc4264a78a9d79620a3 Mon Sep 17 00:00:00 2001 From: Roland McGrath Date: Fri, 30 Aug 2002 01:31:18 +0000 Subject: * sysdeps/mach/_strerror.c (__strerror_r): Add libc_hidden_def. * sysdeps/mach/hurd/pwrite64.c: No libc_hidden_def (__libc_pwrite64). * sysdeps/mach/hurd/dl-sysdep.c (__GI_abort): Define alias for abort. * include/assert.h (__assert_perror_fail): Declare it, do hidden_proto. * assert/assert-perr.c: Add libc_hidden_def. * elf/dl-minimal.c [! NDEBUG] (__assert_perror_fail): New function. * sysdeps/gnu/errlist-compat.awk: Don't fail if there are no versions found at all. * sysdeps/gnu/Versions: File removed. Moved all #errlist-compat sys_errlist stuff to ... * sysdeps/unix/sysv/linux/Versions: ... here. * mach/mach.h: Include . --- elf/dl-minimal.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'elf') diff --git a/elf/dl-minimal.c b/elf/dl-minimal.c index 893a3b1f2e..f4b7e28782 100644 --- a/elf/dl-minimal.c +++ b/elf/dl-minimal.c @@ -209,6 +209,19 @@ Inconsistency detected by ld.so: %s: %u: %s%sAssertion `%s' failed!\n", } rtld_hidden_weak(__assert_fail) +void weak_function +__assert_perror_fail (int errnum, + const char *file, unsigned int line, + const char *function) +{ + char errbuf[400]; + _dl_fatal_printf ("\ +Inconsistency detected by ld.so: %s: %u: %s%sUnexpected error: %s.\n", + file, line, function ?: "", function ? ": " : "", + __strerror_r (errnum, errbuf, sizeof errbuf)); + +} +rtld_hidden_weak (__assert_perror_fail) #endif unsigned long int weak_function -- cgit v1.2.3