]> granicus.if.org Git - strace/commit
rtnl_rule: enhance FRA_TABLE decoding
authorDmitry V. Levin <ldv@altlinux.org>
Tue, 29 Aug 2017 10:09:04 +0000 (10:09 +0000)
committerDmitry V. Levin <ldv@altlinux.org>
Tue, 29 Aug 2017 10:09:04 +0000 (10:09 +0000)
commitc95b9cb23b879c6875c2b5f8c3a1aad96bf20c84
tree8d8971d6dbacd9f310e9fd78ce389f5536be9cdd
parenta6a1bc9abcb22ed01bf9ffd6dbf8ccbadf79ba7d
rtnl_rule: enhance FRA_TABLE decoding

The attribute of FRA_TABLE is not just a 32-bit integer, some constants
have well-known symbolic names like RT_TABLE_DEFAULT.

* rtnl_rule.c (fib_rule_hdr_nla_decoders) <FRA_TABLE>:
Use decode_nla_rt_class.
* tests/nlattr_fib_rule_hdr.c (FRA_TABLE): New macro.
(main): Check FRA_TABLE decoding.
rtnl_rule.c
tests/nlattr_fib_rule_hdr.c