diff options
author | Anil Madhavapeddy <avsm@cvs.openbsd.org> | 2003-09-26 15:51:44 +0000 |
---|---|---|
committer | Anil Madhavapeddy <avsm@cvs.openbsd.org> | 2003-09-26 15:51:44 +0000 |
commit | c543a6d7902c0568a4e844931b6f7c4bccfb6734 (patch) | |
tree | f5045842e072681bd1d36aade7d75a8ec1368df6 /usr.sbin/ndp | |
parent | bd8624665c5403b264ebd60d4f970adfb3f947bf (diff) |
add bounds to sscanf, millert@
Diffstat (limited to 'usr.sbin/ndp')
-rw-r--r-- | usr.sbin/ndp/ndp.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.sbin/ndp/ndp.c b/usr.sbin/ndp/ndp.c index 07c56bc49e2..2f8f7c25be3 100644 --- a/usr.sbin/ndp/ndp.c +++ b/usr.sbin/ndp/ndp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ndp.c,v 1.29 2003/06/26 21:33:33 deraadt Exp $ */ +/* $OpenBSD: ndp.c,v 1.30 2003/09/26 15:51:43 avsm Exp $ */ /* $KAME: ndp.c,v 1.101 2002/07/17 08:46:33 itojun Exp $ */ /* @@ -330,7 +330,7 @@ file(char *name) args[4] = &arg[4][0]; retval = 0; while (fgets(line, 100, fp) != NULL) { - i = sscanf(line, "%s %s %s %s %s", arg[0], arg[1], arg[2], + i = sscanf(line, "%49s %49s %49s %49s %49s", arg[0], arg[1], arg[2], arg[3], arg[4]); if (i < 2) { fprintf(stderr, "ndp: bad line: %s\n", line); |