dirmngr: Factor common libdns code out.
authorWerner Koch <wk@gnupg.org>
Fri, 16 Dec 2016 19:09:27 +0000 (20:09 +0100)
committerWerner Koch <wk@gnupg.org>
Fri, 16 Dec 2016 19:09:27 +0000 (20:09 +0100)
commit59d3c3e4baffff52548fb5d1766ebf02dd8e1bec
tree0489c7fad8ea71914202b2b0699698a08d13f9bb
parent41a426a1a01e2726c3c318786f29b4974bf1f689
dirmngr: Factor common libdns code out.

* dirmngr/dns-stuff.c (libdns_res_open): New.  Replace all libdns_init
and dns-res_open by a call to this func.
(libdns_res_submit): New wrapper.  Replace all dns_res_sumbit calls.
(libdns_res_wait): New function.
(resolve_name_libdns): Replace loop by libdns_res_wait.
(get_dns_cert_libdns): Ditto.
(getsrv_libdns): Ditto.

Signed-off-by: Werner Koch <wk@gnupg.org>
dirmngr/dns-stuff.c