summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Haller <thaller@redhat.com>2019-03-15 09:02:52 +0100
committerThomas Haller <thaller@redhat.com>2019-03-15 09:18:11 +0100
commitf2f72e8245204b206169e42681942e5845bc0a3e (patch)
treeed97de34537fee7ffe236da663b9d91439af8303
parentb24f0a46aefbe41f11fdc30f4048c6df01febc0f (diff)
downloadNetworkManager-f2f72e8245204b206169e42681942e5845bc0a3e.tar.gz
platform/tests: workaround FIB_RULE_INVERT of rules for kernel issue rh#1686075
Fixes: b8398b9e7948 ('platform: add NMPRulesManager for syncing routing rules')
-rw-r--r--src/platform/tests/test-route.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/platform/tests/test-route.c b/src/platform/tests/test-route.c
index c164ef120e..6e01b0b067 100644
--- a/src/platform/tests/test-route.c
+++ b/src/platform/tests/test-route.c
@@ -1300,6 +1300,10 @@ _rule_fuzzy_equal (const NMPObject *obj,
rr_co.flow = 0;
if (rr->tos == 0)
rr_co.tos = 0;
+ if (!NM_FLAGS_HAS (rr->flags, FIB_RULE_INVERT))
+ rr_co.flags &= ~((guint32) FIB_RULE_INVERT);
+ else
+ rr_co.flags |= ((guint32) FIB_RULE_INVERT);
break;
case RTM_DELRULE:
/* when deleting a rule with RTM_DELRULE, kernel tries to find the