projects
/
collectd.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
utils_cmds_test: Add various unit tests for the command parser.
[collectd.git]
/
src
/
ipc.c
diff --git
a/src/ipc.c
b/src/ipc.c
index
b164cdf
..
d6d2bbd
100644
(file)
--- a/
src/ipc.c
+++ b/
src/ipc.c
@@
-97,12
+97,9
@@
static void ipc_submit_g (const char *plugin_instance,
const char *type_instance,
gauge_t value) /* {{{ */
{
const char *type_instance,
gauge_t value) /* {{{ */
{
- value_t values[1];
value_list_t vl = VALUE_LIST_INIT;
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, "ipc", sizeof (vl.plugin));
vl.values_len = 1;
sstrncpy (vl.host, hostname_g, sizeof (vl.host));
sstrncpy (vl.plugin, "ipc", sizeof (vl.plugin));