]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
netlink: support NLMSG_ERROR message in genl
authorYu Watanabe <watanabe.yu+github@gmail.com>
Wed, 13 Mar 2019 07:45:06 +0000 (16:45 +0900)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Thu, 14 Mar 2019 01:57:41 +0000 (10:57 +0900)
This resolves the following log message after L2TP tunnel or session is
created:
```
sd-netlink: ignored message with unknown type: 2
```

src/libsystemd/sd-netlink/netlink-types.c

index 92b044d5aa1c521f73b00aad70e56545ce31a516..8248ac0f5a50234a7a96d39f20af51b1930f634d 100644 (file)
@@ -862,6 +862,7 @@ const NLTypeSystem genl_family_type_system_root = {
 };
 
 static const NLType genl_types[] = {
+        [NLMSG_ERROR]  = { .type = NETLINK_TYPE_NESTED, .type_system = &empty_type_system, .size = sizeof(struct nlmsgerr) },
         [GENL_ID_CTRL] = { .type = NETLINK_TYPE_NESTED, .type_system = &genl_get_family_type_system, .size = sizeof(struct genlmsghdr) },
 };