Home
last modified time | relevance | path

Searched refs:statp (Results 1 – 9 of 9) sorted by relevance

/bionic/libc/dns/resolv/
Dres_init.c160 res_ninit(res_state statp) { in res_ninit() argument
163 return (__res_vinit(statp, 0)); in res_ninit()
168 __res_vinit(res_state statp, int preinit) { in __res_vinit() argument
191 if ((statp->options & RES_INIT) != 0U) in __res_vinit()
192 res_ndestroy(statp); in __res_vinit()
195 statp->netid = NETID_UNSET; in __res_vinit()
196 statp->retrans = RES_TIMEOUT; in __res_vinit()
197 statp->retry = RES_DFLRETRY; in __res_vinit()
198 statp->options = RES_DEFAULT; in __res_vinit()
199 statp->id = res_randomid(); in __res_vinit()
[all …]
Dres_query.c128 res_nquery(res_state statp, in res_nquery() argument
139 oflags = statp->_flags; in res_nquery()
145 if (statp->options & RES_DEBUG) in res_nquery()
149 n = res_nmkquery(statp, QUERY, name, class, type, NULL, 0, NULL, in res_nquery()
152 if (n > 0 && (statp->_flags & RES_F_EDNS0ERR) == 0 && in res_nquery()
153 (statp->options & (RES_USE_EDNS0|RES_USE_DNSSEC)) != 0U) in res_nquery()
154 n = res_nopt(statp, n, buf, sizeof(buf), anslen); in res_nquery()
158 if (statp->options & RES_DEBUG) in res_nquery()
161 RES_SET_H_ERRNO(statp, NO_RECOVERY); in res_nquery()
164 n = res_nsend(statp, buf, n, answer, anslen); in res_nquery()
[all …]
Dres_send.c233 res_ourserver_p(const res_state statp, const struct sockaddr *sa) { in res_ourserver_p() argument
241 for (ns = 0; ns < statp->nscount; ns++) { in res_ourserver_p()
242 srv = (struct sockaddr_in *)(void *)get_nsaddr(statp, (size_t)ns); in res_ourserver_p()
251 if (EXT(statp).ext == NULL) in res_ourserver_p()
254 for (ns = 0; ns < statp->nscount; ns++) { in res_ourserver_p()
255 srv6 = (struct sockaddr_in6 *)(void *)get_nsaddr(statp, (size_t)ns); in res_ourserver_p()
361 res_nsend(res_state statp, in res_nsend() argument
372 DprintQ((statp->options & RES_DEBUG) || (statp->pfcode & RES_PRF_QUERY), in res_nsend()
374 v_circuit = (statp->options & RES_USEVC) || buflen > PACKETSZ; in res_nsend()
380 statp->netid, buf, buflen, in res_nsend()
[all …]
Dres_debug.h26 # define Aerror(statp, file, string, error, address) /*empty*/ argument
27 # define Perror(statp, file, string, error) /*empty*/ argument
32 res_pquery(statp, query, size, stdout);\
Dres_mkquery.c117 res_nmkquery(res_state statp, in res_nmkquery() argument
135 if (statp->options & RES_DEBUG) in res_nmkquery()
148 hp->rd = (statp->options & RES_RECURSE) != 0U; in res_nmkquery()
231 res_nopt(res_state statp, in res_nopt() argument
242 if ((statp->options & RES_DEBUG) != 0U) in res_nopt()
261 if (statp->options & RES_USE_DNSSEC) { in res_nopt()
263 if (statp->options & RES_DEBUG) in res_nopt()
Dres_debug.c137 fp_resstat(const res_state statp, FILE *file) { in fp_resstat() argument
142 if (statp->options & mask) in fp_resstat()
149 do_section(const res_state statp, in do_section() argument
162 sflag = (int)(statp->pfcode & pflag); in do_section()
163 if (statp->pfcode && !sflag) in do_section()
180 (statp->pfcode & RES_PRF_HEAD1)) in do_section()
184 if (rrnum == 0 && sflag != 0 && (statp->pfcode & RES_PRF_HEAD1)) in do_section()
279 res_pquery(const res_state statp, const u_char *msg, int len, FILE *file) { in res_pquery() argument
299 if ((!statp->pfcode) || (statp->pfcode & RES_PRF_HEADX) || rcode) in res_pquery()
303 if ((!statp->pfcode) || (statp->pfcode & RES_PRF_HEADX)) in res_pquery()
[all …]
Dres_private.h20 res_ourserver_p(const res_state statp, const struct sockaddr *sa);
Dres_cache.c2111 _resolv_populate_res_for_net(res_state statp) in _resolv_populate_res_for_net() argument
2113 if (statp == NULL) { in _resolv_populate_res_for_net()
2120 struct resolv_cache_info* info = _find_cache_info_locked(statp->netid); in _resolv_populate_res_for_net()
2124 XLOG("%s: %u\n", __FUNCTION__, statp->netid); in _resolv_populate_res_for_net()
2131 if ((size_t) ai->ai_addrlen <= sizeof(statp->_u._ext.ext->nsaddrs[0])) { in _resolv_populate_res_for_net()
2132 if (statp->_u._ext.ext != NULL) { in _resolv_populate_res_for_net()
2133 memcpy(&statp->_u._ext.ext->nsaddrs[nserv], ai->ai_addr, ai->ai_addrlen); in _resolv_populate_res_for_net()
2134 statp->nsaddr_list[nserv].sin_family = AF_UNSPEC; in _resolv_populate_res_for_net()
2137 <= sizeof(statp->nsaddr_list[0])) { in _resolv_populate_res_for_net()
2138 memcpy(&statp->nsaddr_list[nserv], ai->ai_addr, in _resolv_populate_res_for_net()
[all …]
/bionic/libc/dns/include/
Dresolv_cache.h40 extern void _resolv_populate_res_for_net(struct __res_state* statp);