vnet: allow format deleted swifidx 78/40078/3
authorNathan Skrzypczak <nathan.skrzypczak@gmail.com>
Wed, 6 Dec 2023 16:34:57 +0000 (17:34 +0100)
committerDamjan Marion <dmarion@0xa5.net>
Thu, 7 Dec 2023 10:14:49 +0000 (10:14 +0000)
commit535364e90459566b603661c3dbe360c72f59ad71
tree574bb762d345c7871081233823f00cbb968a35cb
parent327c3230652240c91be2342639c53ee56f868d4d
vnet: allow format deleted swifidx

This patch prevents the sw interfaces format
function to fail when the interface was deleted.
It also prints the swifindex alongside the 'DELETED'
keyword.

Printing deleted swifindex should not happen, but it is still
helpful to have these safeguards for troubleshooting in the case
invariants get corrupted (e.g. fib entry refcounts, ...)

Type: improvement

Change-Id: I66711049db2eebe0ad17e37c3a260ac81d1e5134
Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
src/vnet/fib/fib_path.c
src/vnet/interface.c
src/vnet/interface_format.c