]> git.ipfire.org Git - thirdparty/bird.git/commit
Table: Do not attempt to prune an empty table
authorMaria Matejka <mq@ucw.cz>
Sat, 24 May 2025 12:16:44 +0000 (14:16 +0200)
committerMaria Matejka <mq@ucw.cz>
Sun, 25 May 2025 19:03:44 +0000 (21:03 +0200)
commite77d5e7cb6b51cedefef0c10ad4ac65fecc81937
tree25dc2e78cae4908594148c0f9d18c4b7a7c0829e
parent82244ea23752c1be90311a0ce935ab6be74e2242
Table: Do not attempt to prune an empty table

Table pruning is requested from multiple places, including
a timer. Sometimes this may happen in a race condition with
table shutdown, and therefore we explicitly refuse to schedule
pruning if the table is empty.

Also added a full-blown check that a shutting-down table
is indeed empty, and several more asserts to catch imminent crashes
before they happen in hard-to-debug places.

This fixes #254.
nest/rt-export.c
nest/rt-table.c
proto/bgp/attrs.c