rtnl_route: decode new RTA_* attributes
authorDmitry V. Levin <ldv@altlinux.org>
Sat, 4 Aug 2018 11:45:20 +0000 (11:45 +0000)
committerDmitry V. Levin <ldv@altlinux.org>
Sat, 4 Aug 2018 11:45:20 +0000 (11:45 +0000)
* rtnl_route.c (rtmsg_nla_decoders): Add entries for RTA_IP_PROTO,
RTA_SPORT, and RTA_DPORT.

rtnl_route.c

index ec5d69f43999ed625dd6706928fc410efabb33ec..6619b56bf1caa6131cd86856703a1358ede8320a 100644 (file)
@@ -248,7 +248,10 @@ static const nla_decoder_t rtmsg_nla_decoders[] = {
        [RTA_EXPIRES]           = decode_nla_u64,
        [RTA_PAD]               = NULL,
        [RTA_UID]               = decode_nla_u32,
-       [RTA_TTL_PROPAGATE]     = decode_nla_u8
+       [RTA_TTL_PROPAGATE]     = decode_nla_u8,
+       [RTA_IP_PROTO]          = decode_nla_u8,
+       [RTA_SPORT]             = decode_nla_u16,
+       [RTA_DPORT]             = decode_nla_u16
 };
 
 static bool