diff options
author | tegge <tegge@FreeBSD.org> | 1998-01-18 18:46:20 +0000 |
---|---|---|
committer | tegge <tegge@FreeBSD.org> | 1998-01-18 18:46:20 +0000 |
commit | 5bd44675cc7fc3fcb896c9e50de54eae09f60ca5 (patch) | |
tree | 18f504b5119664beb52fe48053c7ab3e2bbcd912 /sys/nfsclient/bootp_subr.c | |
parent | 47602f273a7d3d3f5393328f6f4072e97202126b (diff) | |
download | FreeBSD-src-5bd44675cc7fc3fcb896c9e50de54eae09f60ca5.zip FreeBSD-src-5bd44675cc7fc3fcb896c9e50de54eae09f60ca5.tar.gz |
Increase the minimum bootp reply packet size from 16 (bogus) to 300 (correct).
Diffstat (limited to 'sys/nfsclient/bootp_subr.c')
-rw-r--r-- | sys/nfsclient/bootp_subr.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/sys/nfsclient/bootp_subr.c b/sys/nfsclient/bootp_subr.c index 1b668e9..1712a80 100644 --- a/sys/nfsclient/bootp_subr.c +++ b/sys/nfsclient/bootp_subr.c @@ -1,4 +1,4 @@ -/* $Id: bootp_subr.c,v 1.6 1997/10/28 15:59:02 bde Exp $ */ +/* $Id: bootp_subr.c,v 1.7 1998/01/09 03:21:07 eivind Exp $ */ /* * Copyright (c) 1995 Gordon Ross, Adam Glass @@ -69,7 +69,7 @@ #include <nfs/xdr_subs.h> -#define MIN_REPLY_HDR 16 /* xid, dir, astat, errno */ +#define BOOTP_MIN_LEN 300 /* Minimum size of bootp udp packet */ /* * What is the longest we will wait before re-sending a request? @@ -390,8 +390,8 @@ bootpc_call(call,reply,procp) goto out; len = sizeof(*reply) - auio.uio_resid; - /* Does the reply contain at least a header? */ - if (len < MIN_REPLY_HDR) + /* Do we have the required number of bytes ? */ + if (len < BOOTP_MIN_LEN) continue; /* Is it the right reply? */ |