From 5a2a9e3b899a0114ec3280dcd8fd5171d1d18a36 Mon Sep 17 00:00:00 2001 From: Donald Sharp Date: Thu, 17 Oct 2024 07:42:47 -0400 Subject: [PATCH] zebra: Fix possible null deref discovered by coverity Signed-off-by: Donald Sharp --- zebra/connected.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/zebra/connected.c b/zebra/connected.c index ce26c14c0525..ce4f6919d546 100644 --- a/zebra/connected.c +++ b/zebra/connected.c @@ -191,6 +191,9 @@ static void connected_remove_kernel_for_connected(afi_t afi, safi_t safi, struct rib_dest_t *dest; struct route_table *table = zebra_vrf_table(afi, SAFI_UNICAST, zvrf->vrf->vrf_id); + if (!table) + return; + rn = route_node_match(table, p); if (!rn) return;