added lease time option to dhcpserver's DHCPOFFER
This commit is contained in:
parent
a721fb0bc7
commit
b6b0e5da13
1 changed files with 3 additions and 0 deletions
|
@ -254,6 +254,9 @@ static void handle_dhcp_discover(struct dhcp_msg *dhcpmsg)
|
||||||
opt = add_dhcp_option_bytes(opt, DHCP_OPTION_DNS_SERVER, &state->dns, 4);
|
opt = add_dhcp_option_bytes(opt, DHCP_OPTION_DNS_SERVER, &state->dns, 4);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
uint32_t expiry = htonl(DHCPSERVER_LEASE_TIME);
|
||||||
|
opt = add_dhcp_option_bytes(opt, DHCP_OPTION_LEASE_TIME, &expiry, 4);
|
||||||
|
|
||||||
opt = add_dhcp_option_bytes(opt, DHCP_OPTION_END, NULL, 0);
|
opt = add_dhcp_option_bytes(opt, DHCP_OPTION_END, NULL, 0);
|
||||||
|
|
||||||
struct netbuf *netbuf = netbuf_new();
|
struct netbuf *netbuf = netbuf_new();
|
||||||
|
|
Loading…
Reference in a new issue