This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Fix localealias.c fgets_unlocked namespace (bug 17589)
- From: Joseph Myers <joseph at codesourcery dot com>
- To: <libc-alpha at sourceware dot org>
- Date: Wed, 12 Nov 2014 17:20:41 +0000
- Subject: Fix localealias.c fgets_unlocked namespace (bug 17589)
- Authentication-results: sourceware.org; auth=none
intl/localealias.c is brought in by ISO C functions, but uses
fgets_unlocked, which is not an ISO C function. This patch, relative
to a tree with
<https://sourceware.org/ml/libc-alpha/2014-11/msg00232.html> applied,
changes this to use fgets_unlocked.
Tested for x86_64 (testsuite, and that stripped installed shared
libraries are unchanged by the patch).
2014-11-12 Joseph Myers <joseph@codesourcery.com>
[BZ #17589]
* intl/localealias.c [_LIBC] (FGETS): Use __fgets_unlocked instead
of fgets_unlocked.
diff --git a/intl/localealias.c b/intl/localealias.c
index 9ab4328..1d3f8eb 100644
--- a/intl/localealias.c
+++ b/intl/localealias.c
@@ -84,7 +84,7 @@ __libc_lock_define_initialized (static, lock);
/* Some optimizations for glibc. */
#ifdef _LIBC
# define FEOF(fp) feof_unlocked (fp)
-# define FGETS(buf, n, fp) fgets_unlocked (buf, n, fp)
+# define FGETS(buf, n, fp) __fgets_unlocked (buf, n, fp)
#else
# define FEOF(fp) feof (fp)
# define FGETS(buf, n, fp) fgets (buf, n, fp)
--
Joseph S. Myers
joseph@codesourcery.com