freebsd-dev/sbin/dhclient
Brooks Davis ebe609b4a2 It is possible for bpf to return a length such that:
length != BPF_WORDALIGN(length)

This meeans that it is possible for this to be true:

	interface->rbuf_offset > interface->rbuf_len

Handle this case in the test for running out of packets.  While
OpenBSD's solution of setting interface->rbuf_len to
BPF_WORDALIGN(length) is safe due to the size of the buffer, I think
this solution results in less hidden assumptions.

This should fix the problem of dhclient running away and consuming 100%
CPU.

PR:		bin/102226
Submitted by:	Joost Bekkers <joost at jodocus.org>
MFC after:	3 days
2006-09-26 01:02:02 +00:00
..
alloc.c
bpf.c It is possible for bpf to return a length such that: 2006-09-26 01:02:02 +00:00
clparse.c
conflex.c
convert.c
dhclient-script Fix rev 1.12. 2006-01-26 21:05:39 +00:00
dhclient-script.8
dhclient.8 Revert the addition of -p. It's flawed in that dhclient should not run 2006-08-21 16:31:31 +00:00
dhclient.c Revert the addition of -p. It's flawed in that dhclient should not run 2006-08-21 16:31:31 +00:00
dhclient.conf
dhclient.conf.5
dhclient.leases.5
dhcp-options.5 Correct RFC for NTP. 2006-02-06 19:22:34 +00:00
dhcp.h
dhcpd.h
dhctoken.h
dispatch.c
errwarn.c
hash.c
inet.c
Makefile
options.c
packet.c
parse.c
privsep.c
privsep.h
tables.c
tree.c
tree.h