Lines Matching refs:statp
84 res_state statp = &_res; in res_init() local
105 if (!statp->retrans) in res_init()
106 statp->retrans = RES_TIMEOUT; in res_init()
107 if (!statp->retry) in res_init()
108 statp->retry = RES_DFLRETRY; in res_init()
109 if (!(statp->options & RES_INIT)) in res_init()
110 statp->options = RES_DEFAULT; in res_init()
112 return (__res_vinit(statp, 1)); in res_init()
127 res_state statp = &_res; in fp_nquery() local
128 if ((statp->options & RES_INIT) == 0U && res_init() == -1) in fp_nquery()
131 res_pquery(statp, msg, len, file); in fp_nquery()
144 res_state statp = &_res; in res_mkquery() local
145 if ((statp->options & RES_INIT) == 0U && res_init() == -1) { in res_mkquery()
146 RES_SET_H_ERRNO(statp, NETDB_INTERNAL); in res_mkquery()
149 return (res_nmkquery(statp, op, dname, class, type, in res_mkquery()
156 res_state statp = &_res; in res_mkupdate() local
157 if ((statp->options & RES_INIT) == 0U && res_init() == -1) { in res_mkupdate()
158 RES_SET_H_ERRNO(statp, NETDB_INTERNAL); in res_mkupdate()
162 return (res_nmkupdate(statp, rrecp_in, buf, buflen)); in res_mkupdate()
171 res_state statp = &_res; in res_query() local
172 if ((statp->options & RES_INIT) == 0U && res_init() == -1) { in res_query()
173 RES_SET_H_ERRNO(statp, NETDB_INTERNAL); in res_query()
176 return (res_nquery(statp, name, class, type, answer, anslen)); in res_query()
198 res_state statp = &_res; in res_send() local
199 if ((statp->options & RES_INIT) == 0U && res_init() == -1) { in res_send()
204 return (res_nsend(statp, buf, buflen, ans, anssiz)); in res_send()
212 res_state statp = &_res; in res_sendsigned() local
213 if ((statp->options & RES_INIT) == 0U && res_init() == -1) { in res_sendsigned()
218 return (res_nsendsigned(statp, buf, buflen, key, ans, anssiz)); in res_sendsigned()
229 res_state statp = &_res; in res_update() local
230 if ((statp->options & RES_INIT) == 0U && res_init() == -1) { in res_update()
231 RES_SET_H_ERRNO(statp, NETDB_INTERNAL); in res_update()
235 return (res_nupdate(statp, rrecp_in, NULL)); in res_update()
244 res_state statp = &_res; in res_search() local
245 if ((statp->options & RES_INIT) == 0U && res_init() == -1) { in res_search()
246 RES_SET_H_ERRNO(statp, NETDB_INTERNAL); in res_search()
250 return (res_nsearch(statp, name, class, type, answer, anslen)); in res_search()
260 res_state statp = &_res; in res_querydomain() local
261 if ((statp->options & RES_INIT) == 0U && res_init() == -1) { in res_querydomain()
262 RES_SET_H_ERRNO(statp, NETDB_INTERNAL); in res_querydomain()
266 return (res_nquerydomain(statp, name, domain, in res_querydomain()
273 res_state statp = &_res; in res_randomid() local
274 if ((statp->options & RES_INIT) == 0U && res_init() == -1) { in res_randomid()
275 RES_SET_H_ERRNO(statp, NETDB_INTERNAL); in res_randomid()
279 return (res_nrandomid(statp)); in res_randomid()
299 res_state statp; in local_hostname_length() local
301 statp = &_res; in local_hostname_length()
302 if (!*statp->defdname) in local_hostname_length()
305 len_domain = strlen(statp->defdname); in local_hostname_length()
307 !strcasecmp(hostname + len_host - len_domain, statp->defdname) && in local_hostname_length()