Skip to content

Commit

Permalink
ipv4: fill in table id when replacing a route
Browse files Browse the repository at this point in the history
When replacing an IPv4 route, tb_id member of the new fib_alias
structure is not set in the replace code path so that the new route is
ignored.

Fixes: 0ddcf43 ("ipv4: FIB Local/MAIN table collapse")
Signed-off-by: Michal Kubecek <[email protected]>
Acked-by: Alexander Duyck <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
  • Loading branch information
mkubecek authored and davem330 committed May 22, 2015
1 parent 44f6731 commit d4e64c2
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions net/ipv4/fib_trie.c
Original file line number Diff line number Diff line change
Expand Up @@ -1164,6 +1164,7 @@ int fib_table_insert(struct fib_table *tb, struct fib_config *cfg)
state = fa->fa_state;
new_fa->fa_state = state & ~FA_S_ACCESSED;
new_fa->fa_slen = fa->fa_slen;
new_fa->tb_id = tb->tb_id;

err = netdev_switch_fib_ipv4_add(key, plen, fi,
new_fa->fa_tos,
Expand Down

0 comments on commit d4e64c2

Please sign in to comment.