summaryrefslogtreecommitdiff
path: root/src/libsystemd/sd-netlink/netlink-socket.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/libsystemd/sd-netlink/netlink-socket.c')
-rw-r--r--src/libsystemd/sd-netlink/netlink-socket.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/libsystemd/sd-netlink/netlink-socket.c b/src/libsystemd/sd-netlink/netlink-socket.c
index 8136cf36ae..84ff7c38c9 100644
--- a/src/libsystemd/sd-netlink/netlink-socket.c
+++ b/src/libsystemd/sd-netlink/netlink-socket.c
@@ -243,7 +243,7 @@ int socket_read_message(sd_netlink *rtnl) {
}
/* check that we support this message type */
- r = type_system_get_type(NULL, &nl_type, new_msg->nlmsg_type);
+ r = type_system_get_type(&type_system_root, &nl_type, new_msg->nlmsg_type);
if (r < 0) {
if (r == -EOPNOTSUPP)
log_debug("sd-netlink: ignored message with unknown type: %i",
@@ -253,7 +253,7 @@ int socket_read_message(sd_netlink *rtnl) {
}
/* check that the size matches the message type */
- if (new_msg->nlmsg_len < NLMSG_LENGTH(nl_type->size)) {
+ if (new_msg->nlmsg_len < NLMSG_LENGTH(type_get_size(nl_type))) {
log_debug("sd-netlink: message larger than expected, dropping");
continue;
}