diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2002-06-01 20:21:50 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2002-06-01 20:21:50 +0000 |
commit | 9ad057f0774e21386f1048e717f3edf1132fd80c (patch) | |
tree | 6cc65b4b868463ab16bd1d69d89f87900255b481 | |
parent | 95b7aa2e4e955b661813b369f6307bda26aca738 (diff) |
more snprintf
-rw-r--r-- | usr.bin/ftp/ftp.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/usr.bin/ftp/ftp.c b/usr.bin/ftp/ftp.c index ccbef5a8278..f0f7de4e66c 100644 --- a/usr.bin/ftp/ftp.c +++ b/usr.bin/ftp/ftp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ftp.c,v 1.45 2002/05/30 06:51:46 deraadt Exp $ */ +/* $OpenBSD: ftp.c,v 1.46 2002/06/01 20:21:49 deraadt Exp $ */ /* $NetBSD: ftp.c,v 1.27 1997/08/18 10:20:23 lukem Exp $ */ /* @@ -67,7 +67,7 @@ #if 0 static char sccsid[] = "@(#)ftp.c 8.6 (Berkeley) 10/27/94"; #else -static char rcsid[] = "$OpenBSD: ftp.c,v 1.45 2002/05/30 06:51:46 deraadt Exp $"; +static char rcsid[] = "$OpenBSD: ftp.c,v 1.46 2002/06/01 20:21:49 deraadt Exp $"; #endif #endif /* not lint */ @@ -1883,7 +1883,7 @@ abort_remote(din) * send IAC in urgent mode instead of DM because 4.3BSD places oob mark * after urgent byte rather than before as is protocol now */ - sprintf(buf, "%c%c%c", IAC, IP, IAC); + snprintf(buf, sizeof buf, "%c%c%c", IAC, IP, IAC); if (send(fileno(cout), buf, 3, MSG_OOB) != 3) warn("abort"); fprintf(cout, "%cABOR\r\n", DM); |