X-Git-Url: https://git.octo.it/?a=blobdiff_plain;f=src%2Ftape.c;fp=src%2Ftape.c;h=5b5cdb4641d9d176599e689c195d8d36d923b113;hb=b42974a9e2d83e70c166cd572725a8d72bd2a1c4;hp=465688ed5cf2a470df3430fed859c44f2b9f83e6;hpb=c6bbc09d2791606d91b5e2434774a5fae921b1e2;p=collectd.git diff --git a/src/tape.c b/src/tape.c index 465688ed..5b5cdb46 100644 --- a/src/tape.c +++ b/src/tape.c @@ -69,8 +69,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)); strncpy (vl.plugin_instance, plugin_instance, sizeof (vl.plugin_instance));