Fix CTRL_ATTR_FAMILY_ID attribute size
This fixes the following kernel error message:
netlink: 'osmo-ggsn': attribute type 1 has an invalid length.
This is due to CTRL_ATTR_FAMILY_ID being defined as a 16bit netlink
attribute, but us encoding it as u32:
netlink/genetlink.c: [CTRL_ATTR_FAMILY_ID] = { .type = NLA_U16 },
let's properly encode it as 16bit and hence resolve the error message.
Change-Id: I41b2719ffc24d7a3420b5980f2a967264e606d91
Closes: OS#3216
diff --git a/src/genl.c b/src/genl.c
index f534221..5d8b9af 100644
--- a/src/genl.c
+++ b/src/genl.c
@@ -152,7 +152,7 @@
genl->cmd = CTRL_CMD_GETFAMILY;
genl->version = 1;
- mnl_attr_put_u32(nlh, CTRL_ATTR_FAMILY_ID, GENL_ID_CTRL);
+ mnl_attr_put_u16(nlh, CTRL_ATTR_FAMILY_ID, GENL_ID_CTRL);
mnl_attr_put_strz(nlh, CTRL_ATTR_FAMILY_NAME, subsys_name);
return nlh;