Skip to content

Commit

Permalink
evdns: add descriptions for DNS_OPTION_*/DNS_OPTIONS_ALL
Browse files Browse the repository at this point in the history
  • Loading branch information
azat committed Mar 31, 2019
1 parent 2ae875e commit 3e0dc1a
Showing 1 changed file with 26 additions and 1 deletion.
27 changes: 26 additions & 1 deletion include/event2/dns.h
Original file line number Diff line number Diff line change
Expand Up @@ -179,11 +179,36 @@ extern "C" {

#define DNS_QUERY_NO_SEARCH 1

/* Allow searching */
#define DNS_OPTION_SEARCH 1
/* Parse "nameserver" and add default if no such section */
#define DNS_OPTION_NAMESERVERS 2
/* Parse additional options like:
* - timeout:
* - getaddrinfo-allow-skew:
* - max-timeouts:
* - max-inflight:
* - attempts:
* - randomize-case:
* - initial-probe-timeout:
*/
#define DNS_OPTION_MISC 4
/* Load hosts file (i.e. "/etc/hosts") */
#define DNS_OPTION_HOSTSFILE 8
#define DNS_OPTIONS_ALL 15
/**
* All above:
* - DNS_OPTION_SEARCH
* - DNS_OPTION_NAMESERVERS
* - DNS_OPTION_MISC
* - DNS_OPTION_HOSTSFILE
*/
#define DNS_OPTIONS_ALL ( \
DNS_OPTION_SEARCH | \
DNS_OPTION_NAMESERVERS | \
DNS_OPTION_MISC | \
DNS_OPTION_HOSTSFILE | \
0 \
)

/* Obsolete name for DNS_QUERY_NO_SEARCH */
#define DNS_NO_SEARCH DNS_QUERY_NO_SEARCH
Expand Down

0 comments on commit 3e0dc1a

Please sign in to comment.