Merge branch 'collectd-4.6' into collectd-4.7
authorFlorian Forster <octo@huhu.verplant.org>
Wed, 27 May 2009 13:03:44 +0000 (15:03 +0200)
committerFlorian Forster <octo@huhu.verplant.org>
Wed, 27 May 2009 13:03:44 +0000 (15:03 +0200)
configure.in
src/rrdtool.c
src/swap.c
src/utils_cache.c

index e13b93e..b032b6f 100644 (file)
@@ -280,6 +280,8 @@ AC_CHECK_HEADERS(IOKit/ps/IOPowerSources.h, [], [],
 have_sys_swap_h="yes"
 AC_CHECK_HEADERS(sys/swap.h vm/anon.h, [], [have_sys_swap_h="no"],
 [
+#undef _FILE_OFFSET_BITS
+#undef _LARGEFILE64_SOURCE
 #if HAVE_SYS_TYPES_H
 #  include <sys/types.h>
 #endif
index 780b2e5..243a8c8 100644 (file)
@@ -601,7 +601,7 @@ static int rrd_cache_flush_identifier (int timeout, const char *identifier)
   status = c_avl_get (cache, key, (void *) &rc);
   if (status != 0)
   {
-    WARNING ("rrdtool plugin: rrd_cache_flush_identifier: "
+    INFO ("rrdtool plugin: rrd_cache_flush_identifier: "
         "c_avl_get (%s) failed. Does that file really exist?",
         key);
     return (status);
index 1779f86..de9b5f3 100644 (file)
  *   Florian octo Forster <octo at verplant.org>
  **/
 
+#if HAVE_CONFIG_H
+# include "config.h"
+# undef HAVE_CONFIG_H
+#endif
+/* avoid swap.h error "Cannot use swapctl in the large files compilation environment" */
+#if HAVE_SYS_SWAP_H && !defined(_LP64) && _FILE_OFFSET_BITS == 64
+#  undef _FILE_OFFSET_BITS
+#  undef _LARGEFILE64_SOURCE
+#endif
+
 #include "collectd.h"
 #include "common.h"
 #include "plugin.h"
index a63c7d1..2995501 100644 (file)
@@ -303,13 +303,13 @@ int uc_check_timeout (void)
       sfree (key);
       cache_free (ce);
     }
-    else if (status == 1) /* persist */
+    else if (status == 2) /* persist */
     {
       DEBUG ("uc_check_timeout: %s is missing, sending notification.",
          keys[i]);
       ce->state = STATE_MISSING;
     }
-    else if (status == 2) /* do not persist */
+    else if (status == 1) /* do not persist */
     {
       if (ce->state == STATE_MISSING)
       {