index 4640a1bc2083b7ff4fa02e83533cf77cb8fcdb15..cffa4a8dac1eb832d2b3c6f44effa759431e5aaa 100644 (file)
Index: rrdtool/src/rrd_tool.c
===================================================================
---- rrdtool.orig/src/rrd_tool.c 2008-02-24 14:05:10.000000000 +0100
-+++ rrdtool/src/rrd_tool.c 2008-02-24 14:24:37.000000000 +0100
+--- rrdtool.orig/src/rrd_tool.c 2008-04-20 02:11:52.000000000 +0200
++++ rrdtool/src/rrd_tool.c 2008-04-20 02:11:58.000000000 +0200
@@ -4,6 +4,8 @@
* rrd_tool.c Startup wrapper
*****************************************************************************/
Index: rrdtool/src/rrd_update.c
===================================================================
---- rrdtool.orig/src/rrd_update.c 2008-02-24 14:05:10.000000000 +0100
-+++ rrdtool/src/rrd_update.c 2008-02-24 14:28:33.000000000 +0100
-@@ -432,7 +432,12 @@
- #ifdef USE_MADVISE
- /* when we use mmaping we tell the kernel the mmap equivalent
- of POSIX_FADV_RANDOM */
-- madvise(rrd_mmaped_file,rrd_filesize,MADV_RANDOM);
-+#ifdef __USE_BSD
-+ madvise(rrd_mmaped_file,rrd_filesize,MADV_RANDOM);
-+#endif
-+#ifdef __USE_XOPEN2K
-+ posix_madvise(rrd_mmaped_file,rrd_filesize,MADV_RANDOM);
+--- rrdtool.orig/src/rrd_update.c 2008-04-20 02:11:52.000000000 +0200
++++ rrdtool/src/rrd_update.c 2008-04-22 15:38:38.000000000 +0200
+@@ -22,6 +22,10 @@
+ #include "rrd_is_thread_safe.h"
+ #include "unused.h"
+
++#ifdef USE_MADVISE
++ #include <sys/mman.h>
+#endif
- #endif
- #endif
- /* loop through the arguments. */
++
+ #if defined(_WIN32) && !defined(__CYGWIN__) && !defined(__CYGWIN32__)
+ /*
+ * WIN32 does not have gettimeofday and struct timeval. This is a quick and dirty