summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorTom Gundersen <teg@jklm.no>2014-03-28 19:11:15 +0100
committerTom Gundersen <teg@jklm.no>2014-03-28 19:16:21 +0100
commitaef0768e6c74c5be7c3422926efd46009342e9c6 (patch)
tree12c47490cc34137736776cdbc5f19ec9a4b6e7ee /src
parentba5596ec2ed65943b66d42fbe6e9ef7ebc79216c (diff)
sd-rtnl: message - don't log about out-of-range attribute types
We will easily get these when running on newer kernels. However, we can safely ignore them as we anyway don't know what to do with them.
Diffstat (limited to 'src')
-rw-r--r--src/libsystemd/sd-rtnl/rtnl-message.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/libsystemd/sd-rtnl/rtnl-message.c b/src/libsystemd/sd-rtnl/rtnl-message.c
index 4c746f9d8a..cfce7659aa 100644
--- a/src/libsystemd/sd-rtnl/rtnl-message.c
+++ b/src/libsystemd/sd-rtnl/rtnl-message.c
@@ -920,10 +920,11 @@ int rtnl_message_parse(sd_rtnl_message *m,
for (; RTA_OK(rta, rt_len); rta = RTA_NEXT(rta, rt_len)) {
type = rta->rta_type;
- if (type > max) {
- log_debug("rtnl: message parse - ignore out of range attribute type");
+ /* if the kernel is newer than the headers we used
+ when building, we ignore out-of-range attributes
+ */
+ if (type > max)
continue;
- }
if (tb[type])
log_debug("rtnl: message parse - overwriting repeated attribute");