diff options
author | Jiri Pirko <jiri@resnulli.us> | 2015-05-22 11:05:58 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2015-05-22 13:59:02 -0400 |
commit | 12c227ec89a70c14e3efcf102c5babece381e172 (patch) | |
tree | 70747dc47795325f195eade171cd4098412c931e /net/core | |
parent | bd5850d39f10f9d216bff69bcbf5938680b862ae (diff) | |
download | op-kernel-dev-12c227ec89a70c14e3efcf102c5babece381e172.zip op-kernel-dev-12c227ec89a70c14e3efcf102c5babece381e172.tar.gz |
flow_dissector: do not break if ports are not needed in flowlabel
This restored previous behaviour. If caller does not want ports to be
filled, we should not break.
Fixes: 06635a35d13d ("flow_dissect: use programable dissector in skb_flow_dissect and friends")
Signed-off-by: Jiri Pirko <jiri@resnulli.us>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/core')
-rw-r--r-- | net/core/flow_dissector.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/net/core/flow_dissector.c b/net/core/flow_dissector.c index 703d059..1f2d893 100644 --- a/net/core/flow_dissector.c +++ b/net/core/flow_dissector.c @@ -221,13 +221,13 @@ flow_label: key_basic->ip_proto = ip_proto; key_basic->thoff = (u16)nhoff; - if (!skb_flow_dissector_uses_key(flow_dissector, - FLOW_DISSECTOR_KEY_PORTS)) - break; - key_ports = skb_flow_dissector_target(flow_dissector, - FLOW_DISSECTOR_KEY_PORTS, - target_container); - key_ports->ports = flow_label; + if (skb_flow_dissector_uses_key(flow_dissector, + FLOW_DISSECTOR_KEY_PORTS)) { + key_ports = skb_flow_dissector_target(flow_dissector, + FLOW_DISSECTOR_KEY_PORTS, + target_container); + key_ports->ports = flow_label; + } return true; } |