]> git.ipfire.org Git - thirdparty/bird.git/commitdiff
BGP: show proto info crash fix if BGP is down
authorMaria Matejka <mq@ucw.cz>
Tue, 25 Jun 2024 13:05:26 +0000 (15:05 +0200)
committerMaria Matejka <mq@ucw.cz>
Wed, 26 Jun 2024 09:30:41 +0000 (11:30 +0200)
proto/bgp/bgp.c

index 3d31b18840a5d7636a51daa649ccfed87bfb016a..b0ec980d36859b0594c5b2a1efa8a1f50edd3593 100644 (file)
@@ -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;