summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: f0398d0)
raw | patch | inline | side by side (parent: f0398d0)
author | Michael Salmon <michael.salmon@ericsson.com> | |
Thu, 16 Jul 2015 07:05:54 +0000 (09:05 +0200) | ||
committer | Florian Forster <octo@collectd.org> | |
Fri, 4 Dec 2015 16:34:57 +0000 (17:34 +0100) |
Fixes: #551
Signed-off-by: Florian Forster <octo@collectd.org>
Signed-off-by: Florian Forster <octo@collectd.org>
src/threshold.c | patch | blob | history |
diff --git a/src/threshold.c b/src/threshold.c
index 391ee932aed1acf208bbd75c5fb56b243605ae0d..a70ec8af441f723a1f381b50c8215c6e9c01b89b 100644 (file)
--- a/src/threshold.c
+++ b/src/threshold.c
{ /* {{{ */
int i;
int status = 0;
+ int old_size = c_avl_size (threshold_tree);
threshold_t th;
break;
}
- if (c_avl_size (threshold_tree) > 0) {
+ /* register callbacks if this is the first time we see a valid config */
+ if ((old_size == 0) && (c_avl_size (threshold_tree) > 0))
+ {
plugin_register_missing ("threshold", ut_missing,
/* user data = */ NULL);
plugin_register_write ("threshold", ut_check_threshold,