projects
/
rrdtool.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
edfc48b
)
src/rrd_daemon.c: Only increate number of updates and datasets if no failure.
author
Florian Forster
<octo@leeloo.home.verplant.org>
Thu, 3 Jul 2008 21:23:05 +0000
(23:23 +0200)
committer
Florian Forster
<octo@leeloo.home.verplant.org>
Thu, 3 Jul 2008 21:23:05 +0000
(23:23 +0200)
src/rrd_daemon.c
patch
|
blob
|
history
diff --git
a/src/rrd_daemon.c
b/src/rrd_daemon.c
index
17dca62
..
eb94e89
100644
(file)
--- a/
src/rrd_daemon.c
+++ b/
src/rrd_daemon.c
@@
-558,10
+558,13
@@
static void *queue_thread_main (void *args __attribute__((unused))) /* {{{ */
for (i = 0; i < values_num; i++)
free (values[i]);
- pthread_mutex_lock (&stats_lock);
- stats_updates_written++;
- stats_data_sets_written += values_num;
- pthread_mutex_unlock (&stats_lock);
+ if (status == 0)
+ {
+ pthread_mutex_lock (&stats_lock);
+ stats_updates_written++;
+ stats_data_sets_written += values_num;
+ pthread_mutex_unlock (&stats_lock);
+ }
pthread_mutex_lock (&cache_lock);
pthread_cond_broadcast (&flush_cond);