]> git.ipfire.org Git - thirdparty/grub.git/commit
net/dhcp: Replace parse_dhcp_vendor() with find_dhcp_option()
authorAndrei Borzenkov <arvidjaar@gmail.com>
Thu, 7 Mar 2019 15:14:08 +0000 (15:14 +0000)
committerDaniel Kiper <daniel.kiper@oracle.com>
Tue, 12 Mar 2019 19:04:07 +0000 (20:04 +0100)
commit4c44bbd83571fbda440f9aabc9917375d56889ba
treec2746d9aedf50c74029bb25e390d00edec6b795b
parent0b5c14c7f6fd7438d9caf1f1aaa459d328a9e3ce
net/dhcp: Replace parse_dhcp_vendor() with find_dhcp_option()

For proper DHCP support we will need to parse DHCP options from a packet
more often and at various places.

Refactor the option parsing into a new function, which will scan a packet to
find *a particular* option field. Use that new function in places where we
were dealing with DHCP options before.

Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
grub-core/net/bootp.c