]> git.puffer.fish Git - mirror/frr.git/commit
ospf6d: Fix setting interface ipv6 ospf6 cost value (LSA hooks were never called)
authorJuergen Kammer <j.kammer@eurodata.de>
Tue, 7 Nov 2017 08:38:22 +0000 (09:38 +0100)
committerDonald Sharp <sharpd@cumulusnetworks.com>
Thu, 9 Nov 2017 15:49:46 +0000 (10:49 -0500)
commit0db8196a967778a8d4e1018329b635b5716d6a08
treee4f0985f1a42d9aef769475d8b5efe8b4afdab53
parentccd2b0e6ce0dbbd8e26a0c98f7d574c0f37d55b9
ospf6d: Fix setting interface ipv6 ospf6 cost value (LSA hooks were never called)

Fixes: #1420
Signed-off-by: Juergen Kammer <j.kammer@eurodata.de>
If the ipv6 ospf6 cost on an interface is changed, no recalculation of routes happens, though the interface structure is updated with the new value. The new cost will be used later, when LSA hooks are called for any other reason.

Diagnosis:
The DEFUN for the config command sets oi->cost and calls ospf6_interface_recalculate_cost(oi) whenever there is a change in the supplied value. ospf6_interface_recalculate_cost then gets the new cost for the interface by calling ospf6_interface_get_cost(oi), which returns oi->cost if a cost is manually set (i.e. we get the value we just set). ospf6_interface_recalculate_cost only calls the LSA hooks if there is a change - which obviously never happens if we compare the new value with itself.
ospf6d/ospf6_interface.c