]> git.puffer.fish Git - mirror/frr.git/commit
ospfd: fix output of dead-interval in show running 8396/head
authorAlexander Chernavin <achernavin@netgate.com>
Fri, 2 Apr 2021 12:55:05 +0000 (08:55 -0400)
committerAlexander Chernavin <achernavin@netgate.com>
Tue, 6 Apr 2021 09:34:55 +0000 (05:34 -0400)
commit6dd632c65d63b015edd4d25fe21c59ca03556858
treedd877fafac4b269d8a2fce7e88a32e697d2410b9
parent61778eb80b48e29c6de44fab4ba767172a94a4e5
ospfd: fix output of dead-interval in show running

When you set OSPF hello-interval for an interface and dead-interval is
not set for this interface, dead-interval will be calculated and set
automatically. "show running-config" will contain an invalid command:

    test(config)# interface vpp1
    test(config-if)# ip ospf area 0
    test(config-if)# ip ospf hello-interval 1
    test(config-if)# exit
    test(config)#
    test(config)# do show running-config
    ...
    interface if1
     ip ospf area 0
     ip ospf dead-interval minimal hello-multiplier 0
     ip ospf hello-interval 1
    !
    ...

It causes frr-reload.py to fail because of this:

    # vtysh -c "show running-config no-header" | vtysh -m -f -
    line 9: % Unknown command:  ip ospf dead-interval minimal hello-multiplier 0
    ...

With this change, output "ip ospf dead-interval" only if it has value
configured explicitly.

Signed-off-by: Alexander Chernavin <achernavin@netgate.com>
ospfd/ospf_vty.c