X-Git-Url: https://git.octo.it/?a=blobdiff_plain;f=src%2Fplugin.c;h=6139baf0de05a2145ac5020d73d2bf64ef2814ae;hb=5a7145dd5626503f411a4aed87f30fc0f9689c90;hp=5a7a52a2984d2007b66209176ef17f3f86383858;hpb=5e44402e816ffa5087a3ec310b78494d06fe4900;p=collectd.git diff --git a/src/plugin.c b/src/plugin.c index 5a7a52a2..6139baf0 100644 --- a/src/plugin.c +++ b/src/plugin.c @@ -573,6 +573,7 @@ int plugin_load (const char *type) else if (!S_ISREG (statbuf.st_mode)) { /* don't follow symlinks */ + WARNING ("stat %s: not a regular file", filename); continue; } @@ -650,7 +651,7 @@ int plugin_register_read (const char *name, read_heap = c_heap_create (plugin_compare_read_func); if (read_heap == NULL) { - ERROR ("plugin_register_complex_read: " + ERROR ("plugin_register_read: " "c_heap_create failed."); return (-1); } @@ -690,8 +691,7 @@ int plugin_register_complex_read (const char *name, read_heap = c_heap_create (plugin_compare_read_func); if (read_heap == NULL) { - ERROR ("plugin_register_complex_read: " - "c_heap_create failed."); + ERROR ("plugin_register_read: c_heap_create failed."); return (-1); } } @@ -1166,6 +1166,9 @@ int plugin_dispatch_values (value_list_t *vl) if (vl->time == 0) vl->time = time (NULL); + if (vl->interval <= 0) + vl->interval = interval_g; + DEBUG ("plugin_dispatch_values: time = %u; interval = %i; " "host = %s; " "plugin = %s; plugin_instance = %s; " @@ -1254,6 +1257,9 @@ int plugin_dispatch_values (value_list_t *vl) /* Update the value cache */ uc_update (ds, vl); + /* Initiate threshold checking */ + ut_check_threshold (ds, vl); + if (post_cache_chain != NULL) { status = fc_process_chain (ds, vl, post_cache_chain);