X-Git-Url: https://git.octo.it/?a=blobdiff_plain;f=src%2Fethstat.c;h=f0b8d9f01f6d87c779d56e3d95cf0e5b4384b7cb;hb=1aa4295ba6875ceb02a7383237bc2485ffab9c1e;hp=d0e77281e69b5d9ff4ff0d1c406a3aaa12b81e8c;hpb=88ad924df0622911c555cea6826933732e91d9cd;p=collectd.git diff --git a/src/ethstat.c b/src/ethstat.c index d0e77281..f0b8d9f0 100644 --- a/src/ethstat.c +++ b/src/ethstat.c @@ -172,7 +172,6 @@ static void ethstat_submit_value (const char *device, { static c_complain_t complain_no_map = C_COMPLAIN_INIT_STATIC; - value_t values[1]; value_list_t vl = VALUE_LIST_INIT; value_map_t *map = NULL; @@ -189,8 +188,7 @@ static void ethstat_submit_value (const char *device, return; } - values[0].derive = value; - vl.values = values; + vl.values = &(value_t) { .derive = value }; vl.values_len = 1; sstrncpy (vl.host, hostname_g, sizeof (vl.host));