Merge branch 'collectd-4.3' into collectd-4.4
[collectd.git] / src / users.c
index 4686443..d0bd63c 100644 (file)
@@ -49,8 +49,8 @@ static void users_submit (gauge_t value)
        vl.values = values;
        vl.values_len = 1;
        vl.time = time (NULL);
-       strcpy (vl.host, hostname_g);
-       strcpy (vl.plugin, "users");
+       sstrncpy (vl.host, hostname_g, sizeof (vl.host));
+       sstrncpy (vl.plugin, "users", sizeof (vl.plugin));
 
        plugin_dispatch_values ("users", &vl);
 } /* void users_submit */