+2007-10-13 Bruno Haible <bruno@clisp.org>
+
+ * lib/freading.h (freading): Enable the use of __freading for
+ glibc >= 2.7.
+ * lib/freading.c (freading): Likewise.
+
2007-10-12 Paul Eggert <eggert@cs.ucla.edu>
* lib/argp-fmtstream.h (ARGP_FS_EI): Work around GCC 4.2.1 diagnostic
/* Specification. */
#include "freading.h"
-/* Don't use glibc's __freading function, see
+/* Don't use glibc's __freading function in glibc < 2.7, see
<http://sourceware.org/bugzilla/show_bug.cgi?id=4359> */
-#if !(HAVE___FREADING && !defined __GLIBC__)
+#if !(HAVE___FREADING && (!defined __GLIBC__ || __GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 7)))
bool
freading (FILE *fp)
STREAM must not be wide-character oriented. */
-#if HAVE___FREADING && !defined __GLIBC__ /* Solaris >= 7, not glibc >= 2.2 */
+#if HAVE___FREADING && (!defined __GLIBC__ || __GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 7))
+/* Solaris >= 7, not glibc >= 2.2, but glibc >= 2.7 */
# include <stdio_ext.h>
# define freading(stream) (__freading (stream) != 0)