From 5b7fd453d4e339de1dfe1726177f9fb7afa3d90c Mon Sep 17 00:00:00 2001 From: Maria Matejka Date: Tue, 25 Jun 2024 15:05:26 +0200 Subject: [PATCH] BGP: show proto info crash fix if BGP is down --- proto/bgp/bgp.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/proto/bgp/bgp.c b/proto/bgp/bgp.c index 3d31b188..b0ec980d 100644 --- a/proto/bgp/bgp.c +++ b/proto/bgp/bgp.c @@ -2855,6 +2855,9 @@ bgp_show_proto_info(struct proto *P) if (c->base_table) cli_msg(-1006, " Base table: %s", c->base_table->name); + if (!c->tx) + continue; + BGP_PTX_LOCK(c->tx, tx); uint bucket_cnt = 0;