dhcpv6: move dhcpv6 message type check for early exit
authorPaul Donald <[email protected]>
Sun, 19 Oct 2025 17:30:38 +0000 (19:30 +0200)
committerÁlvaro Fernández Rojas <[email protected]>
Sun, 19 Oct 2025 17:32:56 +0000 (19:32 +0200)
commit288abd9c40461a00d6a52b40153fbf13c423bc1f
treef1cf88740ba3e3cf0d91164e6ef9fe98f21fa3a7
parentd504458ef5157ebb718c149712a5ef9a1a09e92f
dhcpv6: move dhcpv6 message type check for early exit

Avoid doing a bunch of work if the message type we received is not a
client type and does not warrant a reply. Exit early.

Clarify and comment message type handling.

Signed-off-by: Paul Donald <[email protected]>
Link: https://github.com/openwrt/odhcpd/pull/279
Signed-off-by: Álvaro Fernández Rojas <[email protected]>
src/dhcpv6.c
src/dhcpv6.h