summaryrefslogtreecommitdiffstats
path: root/src/libnfnetlink.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/libnfnetlink.c')
-rw-r--r--src/libnfnetlink.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/libnfnetlink.c b/src/libnfnetlink.c
index 8be9306..b864338 100644
--- a/src/libnfnetlink.c
+++ b/src/libnfnetlink.c
@@ -927,8 +927,13 @@ int nfnl_check_attributes(const struct nfnl_handle *h,
while (NFA_OK(attr, attrlen)) {
unsigned int flavor = NFA_TYPE(attr);
if (flavor) {
- if (flavor > cb->attr_count)
- return -EINVAL;
+ if (flavor > cb->attr_count) {
+ /* we have received an attribute from
+ * the kernel which we don't understand
+ * yet. We have to silently ignore this
+ * for the sake of future compatibility */
+ continue;
+ }
nfa[flavor - 1] = attr;
}
attr = NFA_NEXT(attr, attrlen);