From f75a69f25b0fa3467bd1eaee60444875dc900998 Mon Sep 17 00:00:00 2001 From: Laurent Bercot Date: Fri, 19 Dec 2014 01:51:12 +0000 Subject: struct taia -> tain_t doc fixes --- doc/libs6dns/s6dns-engine.html | 8 +++---- doc/libs6dns/s6dns-resolve.html | 50 ++++++++++++++++++++--------------------- 2 files changed, 29 insertions(+), 29 deletions(-) diff --git a/doc/libs6dns/s6dns-engine.html b/doc/libs6dns/s6dns-engine.html index f0f9573..9a57dcb 100644 --- a/doc/libs6dns/s6dns-engine.html +++ b/doc/libs6dns/s6dns-engine.html @@ -78,7 +78,7 @@ after each use. It contains a stralloc, so it must be freed with

s6dns_engine_t life cycle

- int s6dns_engine_init (s6dns_engine_t *dt, s6dns_ip46list_t const *servers, uint32 options, char const *q, unsigned int qlen, uint16 qtype, struct taia const *deadline, struct taia const *stamp) + int s6dns_engine_init (s6dns_engine_t *dt, s6dns_ip46list_t const *servers, uint32 options, char const *q, unsigned int qlen, uint16 qtype, tain_t const *deadline, tain_t const *stamp)

@@ -161,7 +161,7 @@ for dt.

- void s6dns_engine_nextdeadline (s6dns_engine_t const *dt, struct taia *a) + void s6dns_engine_nextdeadline (s6dns_engine_t const *dt, tain_t *a)

@@ -192,7 +192,7 @@ Should be called in every iteration.

After the iopause()

- int s6dns_engine_timeout (s6dns_engine_t *dt, struct taia const *stamp) + int s6dns_engine_timeout (s6dns_engine_t *dt, tain_t const *stamp)

@@ -206,7 +206,7 @@ recycled.

- int s6dns_engine_event (s6dns_engine_t *dt, struct taia const *stamp) + int s6dns_engine_event (s6dns_engine_t *dt, tain_t const *stamp)

diff --git a/doc/libs6dns/s6dns-resolve.html b/doc/libs6dns/s6dns-resolve.html index bbb3f57..bad7c15 100644 --- a/doc/libs6dns/s6dns-resolve.html +++ b/doc/libs6dns/s6dns-resolve.html @@ -35,9 +35,9 @@ to perform high level synchronous DNS resolution. they can block for a non-negligible amount of time. To avoid unbounded waiting times, they always take 2 arguments at the end, deadline and stamp. deadline is the read-only address of a -struct taia +tain_t containing an absolute time which is the deadline for the function, and -stamp is the read-write address of a struct taia being +stamp is the read-write address of a tain_t being an accurate enough representation of the current absolute time. If the function has not returned by *deadline, then it immediately returns with a failure code and errno set to ETIMEDOUT. In every case, @@ -108,7 +108,7 @@ function is declared in the s6dns-constants.h header.

Basic wrapper around s6dns_engine

- int s6dns_resolve_loop_r_g (s6dns_engine_t *dt, struct taia const *deadline)
+ int s6dns_resolve_loop_r_g (s6dns_engine_t *dt, tain_t const *deadline)
Resolves the query stored in dt. Returns 1 on success or 0 on failure.

@@ -116,14 +116,14 @@ Returns 1 on success or 0 on failure.

Generic resolution functions

- int s6dns_resolve_core_g (s6dns_domain_t const *d, uint16 qtype, struct taia const *deadline)
+ int s6dns_resolve_core_g (s6dns_domain_t const *d, uint16 qtype, tain_t const *deadline)
Resolves the query on domain *d (in packet form), of type qtype. Returns 0 on failure, or 1 on success, in which case s6dns_engine_here contains the answer.

- int s6dns_resolve_parse_g (s6dns_domain_t const *d, uint16 qtype, s6dns_message_rr_func_t *f, void *data, struct taia const *deadline)
+ int s6dns_resolve_parse_g (s6dns_domain_t const *d, uint16 qtype, s6dns_message_rr_func_t *f, void *data, tain_t const *deadline)
Resolves the query on domain *d (in packet form), of type qtype, then parses the answer with function f and stores the result into data. Returns 1 if it succeeds, 0 if no data can be extracted from the answer, or -1 if an @@ -140,7 +140,7 @@ here as a return code of 0 with errno set to ENOENT.

- int s6dns_resolvenoq_g (char const *name, unsigned int len, uint16 qtype, s6dns_message_rr_func_t *f, void *data, struct taia const *deadline)
+ int s6dns_resolvenoq_g (char const *name, unsigned int len, uint16 qtype, s6dns_message_rr_func_t *f, void *data, tain_t const *deadline)
Performs a query of type qtype on name name of length len, without qualifying it. Parses the answer with function f and stores the result into data. Returns 1 if it succeeds, 0 if no data can be extracted, @@ -148,7 +148,7 @@ or -1 if an error occurs. Sets errno in the last two cases.

- int s6dns_resolveq_g (char const *name, unsigned int len, uint16 qtype, s6dns_message_rr_func_t *f, void *data, struct taia const *deadline)
+ int s6dns_resolveq_g (char const *name, unsigned int len, uint16 qtype, s6dns_message_rr_func_t *f, void *data, tain_t const *deadline)
Performs a query of type qtype on name name of length len, qualifying it first. Parses the answer with function f and stores the result into data. Returns 1 if it succeeds, 0 if none of the FQDNs can @@ -156,7 +156,7 @@ get a positive answer, or -1 if an error occurs. Sets errno in the last two case

- int s6dns_resolve_g (char const *name, unsigned int len, uint16 qtype, s6dns_message_rr_func_t *f, void *data, int qualif, struct taia const *deadline)
+ int s6dns_resolve_g (char const *name, unsigned int len, uint16 qtype, s6dns_message_rr_func_t *f, void *data, int qualif, tain_t const *deadline)
Performs a query of type qtype on name name of length len. Qualifies name first if qualif is nonzero; else, does not qualify it. Parses the answer with function f and stores the @@ -167,7 +167,7 @@ get a positive answer, or -1 if an error occurs. Sets errno in the last two case

High-level type-specific functions

- int s6dns_resolve_a_g (stralloc *ips, char const *name, unsigned int len, int qualif, struct taia const *deadline)
+ int s6dns_resolve_a_g (stralloc *ips, char const *name, unsigned int len, int qualif, tain_t const *deadline)
Performs an A query on name name of length len, qualifying it iff qualif is nonzero. Returns -1 if an error occurs, or 0 if no answer can be obtained from servers, or 1 if it succeeds, in which case the IPs are @@ -175,7 +175,7 @@ appended to the stralloc *ips, using 4 bytes per answer.

- int s6dns_resolve_aaaa_g (stralloc *ips, char const *name, unsigned int len, int qualif, struct taia const *deadline)
+ int s6dns_resolve_aaaa_g (stralloc *ips, char const *name, unsigned int len, int qualif, tain_t const *deadline)
Performs an AAAA query on name name of length len, qualifying it iff qualif is nonzero. Returns -1 if an error occurs, or 0 if no answer can be obtained from servers, or 1 if it succeeds, in which case the IPs are @@ -183,7 +183,7 @@ appended to the stralloc *ips, using 16 bytes per answer.

- int s6dns_resolve_aaaaa_g (genalloc *ips, char const *name, unsigned int len, int qualif, struct taia const *deadline)
+ int s6dns_resolve_aaaaa_g (genalloc *ips, char const *name, unsigned int len, int qualif, tain_t const *deadline)
Performs an AAAA query and an A query at the same time on name name of length len, qualifying it first iff qualif is nonzero. Returns -1 if an error occurs, or 0 if no answer @@ -195,7 +195,7 @@ indiscriminately.

- int s6dns_resolve_ptr_g (genalloc *ds, char const *name, unsigned int len, int qualif, struct taia const *deadline)
+ int s6dns_resolve_ptr_g (genalloc *ds, char const *name, unsigned int len, int qualif, tain_t const *deadline)
Performs a PTR query on name name of length len, qualifying it iff qualif is nonzero. Returns -1 if an error occurs, or 0 if no answer can be obtained from servers, or 1 if it succeeds, in which case the domains are @@ -203,7 +203,7 @@ appended to the genalloc *ds, which contains an array of s6dns_doma

- int s6dns_resolve_name4_g (genalloc *ds, char const *ip, struct taia const *deadline)
+ int s6dns_resolve_name4_g (genalloc *ds, char const *ip, tain_t const *deadline)
Performs a PTR query on the in-addr.arpa. name representing the IPv4 address ip (4 network-order bytes). Returns -1 if an error occurs, or 0 if no answer @@ -212,7 +212,7 @@ appended to the genalloc *ds, which contains an array of s6dns_doma

- int s6dns_resolve_name6_g (genalloc *ds, char const *ip, struct taia const *deadline)
+ int s6dns_resolve_name6_g (genalloc *ds, char const *ip, tain_t const *deadline)
Performs a PTR query on the ip6.arpa. name representing the IPv6 address ip (16 network-order bytes). Returns -1 if an error occurs, or 0 if no answer @@ -221,13 +221,13 @@ appended to the genalloc *ds, which contains an array of s6dns_doma

- int s6dns_resolve_name46_g (genalloc *ds, ip46_t const *ip, struct taia const *deadline)
+ int s6dns_resolve_name46_g (genalloc *ds, ip46_t const *ip, tain_t const *deadline)
Calls s6dns_resolve_name6_g() or s6dns_resolve_name4_g() depending on which ip is an IPv6 or IPv4 address.

- int s6dns_resolve_ns_g (genalloc *ds, char const *name, unsigned int len, int qualif, struct taia const *deadline)
+ int s6dns_resolve_ns_g (genalloc *ds, char const *name, unsigned int len, int qualif, tain_t const *deadline)
Performs a NS query on name name of length len, qualifying it iff qualif is nonzero. Returns -1 if an error occurs, or 0 if no answer can be obtained from servers, or 1 if it succeeds, in which case the domains are @@ -235,7 +235,7 @@ appended to the genalloc *ds, which contains an array of s6dns_doma

- int s6dns_resolve_cname_g (genalloc *ds, char const *name, unsigned int len, int qualif, struct taia const *deadline)
+ int s6dns_resolve_cname_g (genalloc *ds, char const *name, unsigned int len, int qualif, tain_t const *deadline)
Performs a CNAME query on name name of length len, qualifying it iff qualif is nonzero. Returns -1 if an error occurs, or 0 if no answer can be obtained from servers, or 1 if it succeeds, in which case the domains are @@ -244,7 +244,7 @@ appended to the genalloc *ds, which contains an array of s6dns_doma

int s6dns_resolve_hinfo_g (genalloc *hinfos, char const *name, -unsigned int len, int qualif, struct taia const *deadline)
+unsigned int len, int qualif, tain_t const *deadline)
Performs an HINFO query on name name of length len, qualifying it iff qualif is nonzero. Returns -1 if an error occurs, or 0 if no answer can be obtained from servers, or 1 if it succeeds, in which case the domains are @@ -254,7 +254,7 @@ appended to the genalloc *hinfos, which contains an array of

int s6dns_resolve_mx_g (genalloc *mxs, char const *name, -unsigned int len, int qualif, struct taia const *deadline)
+unsigned int len, int qualif, tain_t const *deadline)
Performs an MX query on name name of length len, qualifying it iff qualif is nonzero. Returns -1 if an error occurs, or 0 if no answer can be obtained from servers, or 1 if it succeeds, in which case the domains are @@ -264,7 +264,7 @@ appended to the genalloc *mxs, which contains an array of

int s6dns_resolve_soa_g (genalloc *soas, char const *name, -unsigned int len, int qualif, struct taia const *deadline)
+unsigned int len, int qualif, tain_t const *deadline)
Performs an SOA query on name name of length len, qualifying it iff qualif is nonzero. Returns -1 if an error occurs, or 0 if no answer can be obtained from servers, or 1 if it succeeds, in which case the domains are @@ -274,7 +274,7 @@ appended to the genalloc *soas, which contains an array of

int s6dns_resolve_srv_g (genalloc *srvs, char const *name, -unsigned int len, int qualif, struct taia const *deadline)
+unsigned int len, int qualif, tain_t const *deadline)
Performs an SRV query on name name of length len, qualifying it iff qualif is nonzero. Returns -1 if an error occurs, or 0 if no answer can be obtained from servers, or 1 if it succeeds, in which case the domains are @@ -284,7 +284,7 @@ appended to the genalloc *srvs, which contains an array of

int s6dns_resolve_txt_g (stralloc *sa, genalloc *offsets, char const *name, -unsigned int len, int qualif, struct taia const *deadline)
+unsigned int len, int qualif, tain_t const *deadline)
Performs an TXT query on name name of length len, qualifying it iff qualif is nonzero. Returns -1 if an error occurs, or 0 if no answer can be obtained from servers, or 1 if it succeeds, in which case: @@ -302,7 +302,7 @@ The number of appended integers is the total number of answers.

int s6dns_resolven_loop_g (s6dns_engine_t *dtl, unsigned int n, -unsigned int or, struct taia const *deadline)
+unsigned int or, tain_t const *deadline)
Resolves the n queries stored in the array pointed to by dtl, in parallel. If or is zero, it does not return before all answers have arrived. If or is 1, it returns when an answer arrives, but does @@ -338,7 +338,7 @@ initialized. Other codes report various network problems.

int s6dns_resolven_parse_g (s6dns_resolve_t const *list, unsigned int n, -struct taia const *deadline)
+tain_t const *deadline)
Performs n complete resolutions in parallel, parsing the results. Returns 1 in case of success or 0 if a global error occurred.

@@ -356,7 +356,7 @@ A list of valid query types can be found in the s6dns-constants.h header.
  • options : a uint32 containing options passed to s6dns_engine_init().
  • -
  • deadline : a struct taia containing the +
  • deadline : a tain_t containing the deadline for this query, i.e. the query will fail with an ETIMEDOUT code if no answer has arrived by then. Note that the deadline argument given to s6dns_resolven_parse() is a global deadline that -- cgit v1.2.3