]> git.proxmox.com Git - mirror_frr.git/commit
bgpd: fix deadlock in rpki code
authorMarcel Röthke <marcel.roethke@haw-hamburg.de>
Wed, 18 Jul 2018 13:41:34 +0000 (15:41 +0200)
committerMarcel Röthke <marcel.roethke@haw-hamburg.de>
Wed, 22 Aug 2018 14:50:04 +0000 (16:50 +0200)
commit4ce826764487b07c2bc3f2bf0f1986001afd93c0
tree228ca3852b90edafd0961931437fe4e4460a05d5
parent1f063a699b8979d1808673341c5365fed01e9b4a
bgpd: fix deadlock in rpki code

In some situations rtrlib does not release the locks for its internal
data structures before calling a callback. This can lead to deadlocks
when a lot of routes must be revalidated because the sync socket buffer
will fill up and block the rtrlib thread. The bgpd main thread then
waits for rtrlibs internal locks to be released indefinitely.

This is fixed by using nonblocking sockets instead of blocking ones and
setting a flag to revalidate everything, if it would block.

Signed-off-by: Marcel Röthke <marcel.roethke@haw-hamburg.de>
bgpd/bgp_rpki.c