summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 482d9fb)
raw | patch | inline | side by side (parent: 482d9fb)
author | Florian Forster <octo@leeloo.lan.home.verplant.org> | |
Fri, 12 Oct 2007 20:59:15 +0000 (22:59 +0200) | ||
committer | Florian Forster <octo@leeloo.lan.home.verplant.org> | |
Fri, 12 Oct 2007 20:59:15 +0000 (22:59 +0200) |
src/rrdtool.c | patch | blob | history |
diff --git a/src/rrdtool.c b/src/rrdtool.c
index 9fc687285cab7ae9894f3285d086a5f810d52b7f..ab031376cbdc9b1e265a42d0673ca1cf8ea5714f 100644 (file)
--- a/src/rrdtool.c
+++ b/src/rrdtool.c
rrd_cache_flush (-1);
pthread_mutex_unlock (&cache_lock);
+ pthread_mutex_lock (&queue_lock);
+ do_shutdown = 1;
+ pthread_cond_signal (&queue_cond);
+ pthread_mutex_unlock (&queue_lock);
+
/* Wait for all the values to be written to disk before returning. */
if (queue_thread != 0)
{
DEBUG ("rrdtool plugin: queue_thread exited.");
}
- pthread_mutex_lock (&queue_lock);
- do_shutdown = 1;
- pthread_cond_signal (&queue_cond);
- pthread_mutex_unlock (&queue_lock);
-
return (0);
} /* int rrd_shutdown */