From b5d5d7d33219225e050cc59b1785f2b6f40e8bd9 Mon Sep 17 00:00:00 2001 From: Alex Wang Date: Mon, 12 Aug 2013 14:14:52 -0700 Subject: [PATCH 1/1] band: Fix error in bond_choose_output_slave() function. This commit fixes the error introduced by commit 4a1b8f30e59 (bond: Stop using tags.). The error is caused by mistakenly returning 'slave' where 'slave->aux' should be returned. Signed-off-by: Alex Wang Signed-off-by: Ben Pfaff --- lib/bond.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/bond.c b/lib/bond.c index a9278db84..3834774d4 100644 --- a/lib/bond.c +++ b/lib/bond.c @@ -661,11 +661,14 @@ bond_choose_output_slave(struct bond *bond, const struct flow *flow, struct flow_wildcards *wc, uint16_t vlan) { struct bond_slave *slave; + void *aux; ovs_rwlock_rdlock(&rwlock); slave = choose_output_slave(bond, flow, wc, vlan); + aux = slave ? slave->aux : NULL; ovs_rwlock_unlock(&rwlock); - return slave; + + return aux; } /* Rebalancing. */ -- 2.43.0