X-Git-Url: https://git.octo.it/?a=blobdiff_plain;f=src%2Fusers.c;h=1231075a324803bd3fa866396c62563763496e67;hb=062a664da9fbf134f816a11f255ef90054a9de08;hp=4686443e4b25e3d31391bcf0d3a049aa2482c406;hpb=af46a5f31a0e8d4279d63d8ca9232dbd433dfb25;p=collectd.git diff --git a/src/users.c b/src/users.c index 4686443e..1231075a 100644 --- a/src/users.c +++ b/src/users.c @@ -49,10 +49,11 @@ 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)); + sstrncpy (vl.type, "users", sizeof (vl.plugin)); - plugin_dispatch_values ("users", &vl); + plugin_dispatch_values (&vl); } /* void users_submit */ static int users_read (void)