More autoconf work
[collectd.git] / src / ted.c
index 4422ff9..1f49b20 100644 (file)
--- a/src/ted.c
+++ b/src/ted.c
@@ -39,8 +39,7 @@
 #include "common.h"
 #include "plugin.h"
 
-#if HAVE_TERMIOS_H && HAVE_SYS_IOCTL_H && HAVE_MATH_H
-#include <math.h>
+#if HAVE_TERMIOS_H && HAVE_SYS_IOCTL_H
 #include <sys/ioctl.h>
 #include <termios.h>
 #else
@@ -229,14 +228,10 @@ static int ted_open_device(void) {
 } /* int ted_open_device */
 
 static void ted_submit(const char *type, 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, "ted", sizeof(vl.plugin));
   sstrncpy(vl.type, type, sizeof(vl.type));