aboutsummaryrefslogtreecommitdiff
path: root/usr.bin/banner
diff options
context:
space:
mode:
Diffstat (limited to 'usr.bin/banner')
-rw-r--r--usr.bin/banner/banner.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.bin/banner/banner.c b/usr.bin/banner/banner.c
index 57b5c6a69c85..9531dd715759 100644
--- a/usr.bin/banner/banner.c
+++ b/usr.bin/banner/banner.c
@@ -1062,7 +1062,7 @@ main(int argc, char *argv[])
j += strlen(argv[i]) + 1;
if ((message = malloc((size_t)j)) == NULL)
err(1, "malloc");
- strcpy(message, *argv);
+ strlcpy(message, *argv, j);
while (*++argv) {
strlcat(message, " ", j);
strlcat(message, *argv, j);