This is the mail archive of the
libc-alpha@sources.redhat.com
mailing list for the glibc project.
FreeBSD port (8): missing include in fts.c
- From: Bruno Haible <bruno at clisp dot org>
- To: libc-alpha at sources dot redhat dot com
- Date: Tue, 9 Jul 2002 15:45:05 +0200 (CEST)
- Subject: FreeBSD port (8): missing include in fts.c
Hi,
io/fts.c uses the USHRT_MAX macro but does not include <limits.h>.
On FreeBSD I get a compilation error:
fts.c: In function `fts_build':
fts.c:721: `USHRT_MAX' undeclared (first use in this function)
On Linux <limits.h> is included by <sys/param.h> but since
<sys/param.h> is not standardized, one shouldn't rely on it.
2002-07-06 Bruno Haible <bruno@clisp.org>
* io/fts.c: Include <limits.h>.
diff -r -c3 glibc-20020627.bak/io/fts.c glibc-20020627/io/fts.c
--- glibc-20020627.bak/io/fts.c Wed Jan 2 16:05:14 2002
+++ glibc-20020627/io/fts.c Fri Jul 5 01:17:05 2002
@@ -37,6 +37,7 @@
#include <dirent.h>
#include <errno.h>
#include <fts.h>
+#include <limits.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>