From: Florian Forster Date: Wed, 14 Sep 2016 11:59:05 +0000 (+0200) Subject: Merge remote-tracking branch 'github/pr/1931' X-Git-Tag: collectd-5.7.0~95 X-Git-Url: https://git.octo.it/?a=commitdiff_plain;h=51bc7c4a5523f2b03c24e32064b28c7c8426534d;hp=-c;p=collectd.git Merge remote-tracking branch 'github/pr/1931' --- 51bc7c4a5523f2b03c24e32064b28c7c8426534d diff --combined src/apache.c index f0af8c32,20a2a3cd..578b8dee --- a/src/apache.c +++ b/src/apache.c @@@ -244,7 -244,7 +244,7 @@@ static int config_add (oconfig_item_t * ssnprintf (callback_name, sizeof (callback_name), "apache/%s/%s", (st->host != NULL) ? st->host : hostname_g, - (st->name != NULL) ? st->name : "default"), + (st->name != NULL) ? st->name : "default"); status = plugin_register_complex_read (/* group = */ NULL, /* name = */ callback_name, @@@ -411,19 -411,15 +411,15 @@@ static void submit_value (const char *t } /* void submit_value */ static void submit_derive (const char *type, const char *type_instance, - derive_t c, apache_t *st) + derive_t d, apache_t *st) { - value_t v; - v.derive = c; - submit_value (type, type_instance, v, st); + submit_value (type, type_instance, (value_t) { .derive = d }, st); } /* void submit_derive */ static void submit_gauge (const char *type, const char *type_instance, gauge_t g, apache_t *st) { - value_t v; - v.gauge = g; - submit_value (type, type_instance, v, st); + submit_value (type, type_instance, (value_t) { .gauge = g }, st); } /* void submit_gauge */ static void submit_scoreboard (char *buf, apache_t *st)