Always use flagcmp for RHS bitmask expressions, independant of whether
only one or an entire list of bitmask expression is specified.
This makes sure that f.i. "tcp flags ack" will match any combinations
of ACK instead of ACK and only ACK.
Signed-off-by: Patrick McHardy <kaber@trash.net>
rel->op = OP_FLAGCMP;
break;
default:
- rel->op = OP_EQ;
+ if (right->dtype->basetype != NULL &&
+ right->dtype->basetype->type == TYPE_BITMASK)
+ rel->op = OP_FLAGCMP;
+ else
+ rel->op = OP_EQ;
break;
}
}