X-Git-Url: https://git.verplant.org/?a=blobdiff_plain;f=src%2Fmbmon.c;h=87e54fa18406dd44a4d07a2822b00a90c79083fe;hb=a4b9c9ad2d77656892026ad4b51f9fb7c2a58149;hp=9629b8960d67da5960f957d89f48bfd0c40f500c;hpb=5523a080010dcb7a61dc0dccc3969a2a048e52f9;p=collectd.git diff --git a/src/mbmon.c b/src/mbmon.c index 9629b896..87e54fa1 100644 --- a/src/mbmon.c +++ b/src/mbmon.c @@ -218,14 +218,10 @@ static int mbmon_config (const char *key, const char *value) static void mbmon_submit (const char *type, const char *type_instance, double value) { - value_t values[1]; value_list_t vl = VALUE_LIST_INIT; - values[0].gauge = value; - - vl.values = values; + vl.values = &(value_t) { .gauge = value }; vl.values_len = 1; - sstrncpy (vl.host, hostname_g, sizeof (vl.host)); sstrncpy (vl.plugin, "mbmon", sizeof (vl.plugin)); sstrncpy (vl.type, type, sizeof (vl.type)); sstrncpy (vl.type_instance, type_instance, sizeof (vl.type_instance));