src/common.[ch]: Implement "parse_identifier_vl".
[collectd.git] / src / tape.c
index 67750ef..32b4296 100644 (file)
@@ -68,9 +68,8 @@ static void tape_submit (const char *plugin_instance,
 
        vl.values = values;
        vl.values_len = 2;
-       vl.time = time (NULL);
-       strcpy (vl.host, hostname_g);
-       strcpy (vl.plugin, "tape");
+       sstrncpy (vl.host, hostname_g, sizeof (vl.host));
+       sstrncpy (vl.plugin, "tape", sizeof (vl.plugin));
        sstrncpy (vl.plugin_instance, plugin_instance,
                        sizeof (vl.plugin_instance));
        sstrncpy (vl.type, type, sizeof (vl.type));