summaryrefslogtreecommitdiff
path: root/lib/bfd.c
diff options
context:
space:
mode:
authorAlex Wang <alexw@nicira.com>2013-08-14 13:12:33 -0700
committerBen Pfaff <blp@nicira.com>2013-08-14 13:49:40 -0700
commit2d21cf728c148ab4a06eba2455878f8592ebeead (patch)
treee8c0e3d2ad68ff2c2aa7dd9179d8e5710ed788e7 /lib/bfd.c
parente019a574fe225cd7b2afebe06627ec2c3d58fc57 (diff)
downloadopenvswitch-2d21cf728c148ab4a06eba2455878f8592ebeead.tar.gz
bfd: Fix check_tnl_key error.
This commit fixes the bug introduced by commit 26131299fa5 (bfd: Make the BFD module thread safe.). The bug caused the opposite of the intended behaviour. Unit test is added for the 'check_tnl_key' feature. Signed-off-by: Alex Wang <alexw@nicira.com> Signed-off-by: Ben Pfaff <blp@nicira.com>
Diffstat (limited to 'lib/bfd.c')
-rw-r--r--lib/bfd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/bfd.c b/lib/bfd.c
index 7c7c0b740..b924e3c8f 100644
--- a/lib/bfd.c
+++ b/lib/bfd.c
@@ -516,7 +516,7 @@ bfd_should_process_flow(const struct bfd *bfd, const struct flow *flow,
return (flow->dl_type == htons(ETH_TYPE_IP)
&& flow->nw_proto == IPPROTO_UDP
&& flow->tp_dst == htons(BFD_DEST_PORT)
- && (check_tnl_key || flow->tunnel.tun_id == htonll(0)));
+ && (!check_tnl_key || flow->tunnel.tun_id == htonll(0)));
}
void