From: Michal Bebjak Date: Thu, 3 Sep 2015 10:21:05 +0000 (+0200) Subject: Fix compilation for master X-Git-Tag: collectd-5.6.0~600^2~1 X-Git-Url: https://git.verplant.org/?a=commitdiff_plain;h=61499cf0949d098445ba3fb6b25e09d892990cab;p=collectd.git Fix compilation for master --- diff --git a/src/dbi.c b/src/dbi.c index 0a3d8607..94d0762d 100644 --- a/src/dbi.c +++ b/src/dbi.c @@ -399,8 +399,6 @@ static int cdbi_config_add_database (oconfig_item_t *ci) /* {{{ */ { user_data_t ud; char *name = NULL; - struct timespec interval = { 0, 0 }; - CDTIME_T_TO_TIMESPEC (db->interval, &interval); databases = temp; databases[databases_num] = db; @@ -414,7 +412,7 @@ static int cdbi_config_add_database (oconfig_item_t *ci) /* {{{ */ plugin_register_complex_read (/* group = */ NULL, /* name = */ name ? name : db->name, /* callback = */ cdbi_read_database, - /* interval = */ (db->interval > 0) ? &interval : NULL, + /* interval = */ (db->interval > 0) ? db->interval : 0, /* user_data = */ &ud); free (name); }