diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2003-06-25 03:29:47 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2003-06-25 03:29:47 +0000 |
commit | b1f1e6786a199be973917401fc7eade098b1f8f6 (patch) | |
tree | 26208d1f2ef3e83a1da20928a60e1c665cb921a0 | |
parent | 1cd2fb26fef796050ceec20b67b02b954e22f590 (diff) |
snprintf
-rw-r--r-- | usr.bin/diff/diffdir.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/usr.bin/diff/diffdir.c b/usr.bin/diff/diffdir.c index a036d77551c..89b9a0a9cc3 100644 --- a/usr.bin/diff/diffdir.c +++ b/usr.bin/diff/diffdir.c @@ -1,4 +1,4 @@ -/* $OpenBSD: diffdir.c,v 1.4 2003/06/25 03:25:29 tedu Exp $ */ +/* $OpenBSD: diffdir.c,v 1.5 2003/06/25 03:29:46 deraadt Exp $ */ /* * Copyright (C) Caldera International Inc. 2001-2002. @@ -361,7 +361,8 @@ calldiff(char *wantpr) prargs[2] = wantpr; fflush(stdout); if (wantpr) { - sprintf(etitle, "%s %s", file1, file2); + snprintf(etitle, title + sizeof title - etitle, + "%s %s", file1, file2); pipe(pv); pid = fork(); if (pid == -1) { |