]> git.puffer.fish Git - matthieu/frr.git/commit
zebra: Fix wrong vrf change procedure
authoranlan_cs <vic.lan@pica8.com>
Mon, 22 May 2023 10:32:23 +0000 (18:32 +0800)
committeranlan_cs <vic.lan@pica8.com>
Thu, 13 Jul 2023 07:25:31 +0000 (15:25 +0800)
commita99521a26f7ca02bc4d4d9dcc36b8f80a4c3d2f7
treeb56b98c67343105cb698c74cbc870a86475bf1e1
parent88236d4e952fa05274d5464236a8df4727a6a1c7
zebra: Fix wrong vrf change procedure

Currently the vrf change procedure for the deleted interface is after
its deletion, it causes problem for upper daemons.

Here is the problem of `bgp`:

After deletion of one **irrelevant** interface in the same vrf, its
`ifindex` is set to 0. And then, the vrf change procedure will send
"ZEBRA_INTERFACE_DOWN" to `bgpd`.

Normally, `bgp_nht_ifp_table_handle()` should igore this message for
no correlation. However, it wrongly matched `ifindex` of 0, and removed
the related routes for the down `bnc`.

Adjust the location of the vrf change procedure to fix this issue.

Signed-off-by: anlan_cs <vic.lan@pica8.com>
zebra/interface.c