Code

collectd.conf(5): Document the per-plugin interval configuration.
[collectd.git] / src / bind.c
index db8a891f17252430b104184042918812e05e8534..363668b2b3a8c6813ae6f5ebfa285d2eb1a1a799 100644 (file)
@@ -243,7 +243,7 @@ static void submit (time_t ts, const char *plugin_instance, /* {{{ */
     const char *type, const char *type_instance, value_t value)
 {
   value_t values[1];
-  value_list_t vl = VALUE_LIST_INIT;
+  value_list_t vl = VALUE_LIST_INIT (plugin_interval);
 
   values[0] = value;
 
@@ -1385,6 +1385,7 @@ static int bind_init (void) /* {{{ */
     return (-1);
   }
 
+  curl_easy_setopt (curl, CURLOPT_NOSIGNAL, 1);
   curl_easy_setopt (curl, CURLOPT_WRITEFUNCTION, bind_curl_callback);
   curl_easy_setopt (curl, CURLOPT_USERAGENT, PACKAGE_NAME"/"PACKAGE_VERSION);
   curl_easy_setopt (curl, CURLOPT_ERRORBUFFER, bind_curl_error);
@@ -1430,11 +1431,12 @@ static int bind_shutdown (void) /* {{{ */
   return (0);
 } /* }}} int bind_shutdown */
 
-void module_register (void)
+void module_register (plugin_loaddata_t *data)
 {
+  PLUGIN_INIT_INTERVAL (data);
   plugin_register_complex_config ("bind", bind_config);
   plugin_register_init ("bind", bind_init);
-  plugin_register_read ("bind", bind_read);
+  plugin_register_read ("bind", bind_read, plugin_interval);
   plugin_register_shutdown ("bind", bind_shutdown);
 } /* void module_register */