rrdtool and rrdcached plugins: Don't update the file if ...
authorFlorian Forster <octo@collectd.org>
Mon, 25 Feb 2013 20:08:15 +0000 (21:08 +0100)
committerFlorian Forster <octo@collectd.org>
Mon, 25 Feb 2013 20:08:15 +0000 (21:08 +0100)
... it is being created asynchronously.

src/rrdcached.c
src/rrdtool.c

index a37b4b5..0a98035 100644 (file)
@@ -463,6 +463,8 @@ static int rc_write (const data_set_t *ds, const value_list_t *vl,
             filename);
         return (-1);
       }
+      else if (rrdcreate_config.async)
+        return (0);
     }
   }
 
index a673879..e7c48c0 100644 (file)
@@ -913,6 +913,8 @@ static int rrd_write (const data_set_t *ds, const value_list_t *vl,
                                        ds, vl, &rrdcreate_config);
                        if (status != 0)
                                return (-1);
+                       else if (rrdcreate_config.async)
+                               return (0);
                }
                else
                {