From 68f1ba4ba4b9cb4661ca3ed446d0967ca79c2a47 Mon Sep 17 00:00:00 2001 From: Joseph Myers Date: Wed, 17 Jun 2015 20:13:07 +0000 Subject: Fix fmtmsg addseverity namespace (bug 18539). Use of fmtmsg (XSI POSIX) brings in addseverity (non-POSIX). This patch fixes this by making addseverity into a weak alias for __addseverity. Tested for x86_64 and x86 (testsuite, and that disassembly of installed shared libraries is unchanged by the patch). [BZ #18539] * stdlib/fmtmsg.c (addseverity): Rename to __addseverity and define as weak alias of __addseverity. * conform/Makefile (test-xfail-XPG4/fmtmsg.h/linknamespace): Remove variable. (test-xfail-UNIX98/fmtmsg.h/linknamespace): Likewise. (test-xfail-XOPEN2K/fmtmsg.h/linknamespace): Likewise. (test-xfail-XOPEN2K8/fmtmsg.h/linknamespace): Likewise. --- stdlib/fmtmsg.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'stdlib') diff --git a/stdlib/fmtmsg.c b/stdlib/fmtmsg.c index 6046744..b8133dc 100644 --- a/stdlib/fmtmsg.c +++ b/stdlib/fmtmsg.c @@ -347,7 +347,7 @@ internal_addseverity (int severity, const char *string) /* Add new severity level or remove old one. */ int -addseverity (int severity, const char *string) +__addseverity (int severity, const char *string) { int result; @@ -366,6 +366,7 @@ addseverity (int severity, const char *string) return result; } +weak_alias (__addseverity, addseverity) libc_freeres_fn (free_mem) -- cgit v1.1