Home GnuPG
Diffusion GnuPG c4e8a3194d6b

dirmngr: Use one context for all libdns queries.
c4e8a3194d6bUnpublished

Unpublished Commit · Learn More

Not On Permanent Ref: This commit is not an ancestor of any permanent ref.

Description

dirmngr: Use one context for all libdns queries.

* dirmngr/dns-stuff.c (libdns_reinit_pending): New var.
(enable_recursive_resolver): Set var.
(set_dns_nameserver): Ditto.
(libdns_init): Avoid double initialization.
(libdns_deinit): New.
(reload_dns_stuff): New.
(libdns_res_open): Act upon LIBDNS_REINIT_PENDING.
* dirmngr/t-dns-stuff.c (main): Call reload_dns_stuff to release
memory.
* dirmngr/dirmngr.c (cleanup): Ditto.
(dirmngr_sighup_action): Call reload_dns_stuff to set
LIBDNS_REINIT_PENDING.
  • Signed-off-by: Werner Koch <wk@gnupg.org>

Details

Provenance
wernerAuthored on Dec 16 2016, 9:00 PM
Parents
rGddb48086833f: dirmngr: Pass Tor credentials to libdns.
Branches
Unknown
Tags
Unknown

Event Timeline

Werner Koch <wk@gnupg.org> committed rGc4e8a3194d6b: dirmngr: Use one context for all libdns queries. (authored by Werner Koch <wk@gnupg.org>).Dec 16 2016, 9:00 PM