]> git.ipfire.org Git - thirdparty/bind9.git/commit
Make dns_dt_send() call dns_dt_reopen() asynchronously
authorMichał Kępień <michal@isc.org>
Mon, 5 Feb 2018 20:04:39 +0000 (21:04 +0100)
committerMichał Kępień <michal@isc.org>
Fri, 16 Feb 2018 08:37:23 +0000 (09:37 +0100)
commit5f12985f0b3fd79fc88157801f8cc22e3c82e5d9
treefff8765a22d0c2c06d435bbe01935e20990d66ec
parent2c1307f0610f58a1f21c62fbc330b12908ce5af1
Make dns_dt_send() call dns_dt_reopen() asynchronously

Instead of checking current dnstap output file size and potentially
synchronously calling dns_dt_reopen() upon every call to dns_dt_send():

  - call dns_dt_reopen() asynchronously by queuing an event to the task
    specified at dnstap environment creation time,

  - ensure no roll event is outstanding before checking dnstap output
    file size and potentially queuing another roll event.

This causes dnstap output files to exceed their configured size limits,
but prevents any two threads from performing the roll simultaneously
(which causes crashes).
lib/dns/dnstap.c