Question about PacketFilterBase canPushPacket implementation #964
haug-den-lucas
started this conversation in
General
Replies: 1 comment 1 reply
-
The conditions are derived from the following rules:
So if backpressure is not allowed, then a packet that doesn't match the filter can be pushed into the module, but it will be deleted. Does this answer your question? |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello,
I'm currently working with some Per-Stream Filtering and Policing in INET and stumbled upon the following lines of code:
inet/src/inet/queueing/base/PacketFilterBase.cc
Lines 65 to 71 in 61410b4
In the no-backpressure case, this code accepts all packets in case its consumer accepts all packets.
However, if the consumer does not accept packets, canPushPacket returns true iff the packet criteria does not match, meaning it accepts all packets it will immediately filter out.
I cannot think about any scenario why this implementation would be useful.
Could you please clarify why it is implemented like this?
Beta Was this translation helpful? Give feedback.
All reactions