This is the mail archive of the
libc-alpha@sources.redhat.com
mailing list for the glibc project.
FreeBSD port (7): missing include in sprof.c
- From: Bruno Haible <bruno at clisp dot org>
- To: libc-alpha at sources dot redhat dot com
- Date: Tue, 9 Jul 2002 15:44:41 +0200 (CEST)
- Subject: FreeBSD port (7): missing include in sprof.c
Hi,
elf/sprof.c uses the ULONG_MAX macro but does not include <limits.h>.
On FreeBSD I get a compilation error:
sprof.c: In function `load_shobj':
sprof.c:484: `ULONG_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>
* elf/sprof.c: Include <limits.h>.
diff -r -c3 glibc-20020627.bak/elf/sprof.c glibc-20020627/elf/sprof.c
--- glibc-20020627.bak/elf/sprof.c Sat Mar 2 04:07:58 2002
+++ glibc-20020627/elf/sprof.c Fri Jul 5 01:16:54 2002
@@ -25,6 +25,7 @@
#include <fcntl.h>
#include <inttypes.h>
#include <libintl.h>
+#include <limits.h>
#include <locale.h>
#include <obstack.h>
#include <search.h>