From c095e5b02b2c180d3fa7c140c7589b4bd123a557 Mon Sep 17 00:00:00 2001 From: Yu Watanabe Date: Sat, 25 May 2019 00:37:00 +0900 Subject: [PATCH] netlink: set attribute size of IFLA_STATS and IFLA_STATS64 --- src/libsystemd/sd-netlink/netlink-types.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/libsystemd/sd-netlink/netlink-types.c b/src/libsystemd/sd-netlink/netlink-types.c index 35ca843569..0ac3d1664b 100644 --- a/src/libsystemd/sd-netlink/netlink-types.c +++ b/src/libsystemd/sd-netlink/netlink-types.c @@ -519,7 +519,9 @@ static const NLType rtnl_link_types[] = { [IFLA_LINK] = { .type = NETLINK_TYPE_U32 }, /* [IFLA_QDISC], - [IFLA_STATS], +*/ + [IFLA_STATS] = { .size = sizeof(struct rtnl_link_stats) }, +/* [IFLA_COST], [IFLA_PRIORITY], */ @@ -541,7 +543,9 @@ static const NLType rtnl_link_types[] = { /* [IFLA_NUM_VF], [IFLA_VFINFO_LIST] = {. type = NETLINK_TYPE_NESTED, }, - [IFLA_STATS64], +*/ + [IFLA_STATS64] = { .size = sizeof(struct rtnl_link_stats64) }, +/* [IFLA_VF_PORTS] = { .type = NETLINK_TYPE_NESTED }, [IFLA_PORT_SELF] = { .type = NETLINK_TYPE_NESTED }, */