]> git.ipfire.org Git - thirdparty/bind9.git/commit
tracing of active sockets and handles
authorWitold Kręcicki <wpk@isc.org>
Wed, 2 Sep 2020 15:57:44 +0000 (17:57 +0200)
committerOndřej Surý <ondrej@sury.org>
Thu, 1 Oct 2020 16:09:35 +0000 (18:09 +0200)
commit4a7dfd69acb74999ee2837ae159b24e1a5dfc31d
tree165b47f3b7fdc8d1687b3161b7698934af0988dd
parent686b73ae257a8e608b4bffeddbe709f05ca44f26
tracing of active sockets and handles

If NETMGR_TRACE is defined, we now maintain a list of active sockets
in the netmgr object and a list of active handles in each socket
object; by walking the list and printing `backtrace` in a debugger
we can see where they were created, to assist in in debugging of
reference counting errors.

On shutdown, if netmgr finds there are still active sockets after
waiting, isc__nm_dump_active() will be called to log the list of
active sockets and their underlying handles, along with some details
about them.

(cherry picked from commit 00e04a86c8b6828a066573031cc539adab565061)
lib/isc/netmgr/netmgr-int.h
lib/isc/netmgr/netmgr.c