diff options
Diffstat (limited to 'src/expect/compare.c')
-rw-r--r-- | src/expect/compare.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/expect/compare.c b/src/expect/compare.c index 65ec9c2..c1bb50f 100644 --- a/src/expect/compare.c +++ b/src/expect/compare.c @@ -36,6 +36,13 @@ cmp_exp_flags(const struct nf_expect *exp1, const struct nf_expect *exp, return (exp->flags == exp->flags); } +static int +cmp_exp_class(const struct nf_expect *exp1, const struct nf_expect *exp, + unsigned int flags) +{ + return (exp->class == exp->class); +} + int __cmp_expect(const struct nf_expect *exp1, const struct nf_expect *exp2, unsigned int flags) @@ -54,6 +61,8 @@ int __cmp_expect(const struct nf_expect *exp1, } if (!exp_cmp(ATTR_EXP_FLAGS, exp1, exp2, flags, cmp_exp_flags)) return 0; + if (!exp_cmp(ATTR_EXP_CLASS, exp1, exp2, flags, cmp_exp_class)) + return 0; return 1; } |