udhcpc: add support for DHCP option 212 (RFC 5969)
The patch is from OpenWRT people. function old new delta xmalloc_optname_optval 637 874 +237 dhcp_option_strings 237 243 +6 dhcp_optflags 68 70 +2 len_of_option_as_string 12 13 +1 dhcp_option_lengths 12 13 +1 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 5/0 up/down: 247/0) Total: 247 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
@@ -59,6 +59,7 @@ const struct dhcp_optflag dhcp_optflags[] = {
|
||||
{ OPTION_U16 , 0x84 }, /* DHCP_VLAN_ID */
|
||||
{ OPTION_U8 , 0x85 }, /* DHCP_VLAN_PRIORITY */
|
||||
#endif
|
||||
{ OPTION_6RD , 0xd4 }, /* DHCP_6RD */
|
||||
{ OPTION_STATIC_ROUTES , 0xf9 }, /* DHCP_MS_STATIC_ROUTES */
|
||||
{ OPTION_STRING , 0xfc }, /* DHCP_WPAD */
|
||||
|
||||
@@ -126,6 +127,7 @@ const char dhcp_option_strings[] ALIGN1 =
|
||||
"vlanid" "\0" /* DHCP_VLAN_ID */
|
||||
"vlanpriority" "\0"/* DHCP_VLAN_PRIORITY */
|
||||
#endif
|
||||
"ip6rd" "\0" /* DHCP_6RD */
|
||||
"msstaticroutes""\0"/* DHCP_MS_STATIC_ROUTES */
|
||||
"wpad" "\0" /* DHCP_WPAD */
|
||||
;
|
||||
@@ -154,6 +156,7 @@ const uint8_t dhcp_option_lengths[] ALIGN1 = {
|
||||
[OPTION_S32] = 4,
|
||||
/* Just like OPTION_STRING, we use minimum length here */
|
||||
[OPTION_STATIC_ROUTES] = 5,
|
||||
[OPTION_6RD] = 22, /* ignored by udhcp_str2optset */
|
||||
};
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user