Lines Matching refs:this
123 static void ho_close(struct irs_ho *this);
124 static struct hostent * ho_byname(struct irs_ho *this, const char *name);
125 static struct hostent * ho_byname2(struct irs_ho *this, const char *name,
127 static struct hostent * ho_byaddr(struct irs_ho *this, const void *addr,
129 static struct hostent * ho_next(struct irs_ho *this);
130 static void ho_rewind(struct irs_ho *this);
131 static void ho_minimize(struct irs_ho *this);
132 static struct __res_state * ho_res_get(struct irs_ho *this);
133 static void ho_res_set(struct irs_ho *this,
136 static struct addrinfo * ho_addrinfo(struct irs_ho *this, const char *name,
140 static int init(struct irs_ho *this);
151 irs_lcl_ho(struct irs_acc *this) { in irs_lcl_ho() argument
155 UNUSED(this); in irs_lcl_ho()
185 ho_close(struct irs_ho *this) { in ho_close() argument
186 struct pvt *pvt = (struct pvt *)this->private; in ho_close()
188 ho_minimize(this); in ho_close()
194 memput(this, sizeof *this); in ho_close()
198 ho_byname(struct irs_ho *this, const char *name) { in ho_byname() argument
199 struct pvt *pvt = (struct pvt *)this->private; in ho_byname()
202 if (init(this) == -1) in ho_byname()
206 hp = ho_byname2(this, name, AF_INET6); in ho_byname()
210 return (ho_byname2(this, name, AF_INET)); in ho_byname()
214 ho_byname2(struct irs_ho *this, const char *name, int af) { in ho_byname2() argument
215 struct pvt *pvt = (struct pvt *)this->private; in ho_byname2()
220 if (init(this) == -1) in ho_byname2()
223 ho_rewind(this); in ho_byname2()
225 while ((hp = ho_next(this)) != NULL) { in ho_byname2()
249 ho_byaddr(struct irs_ho *this, const void *addr, int len, int af) { in ho_byaddr() argument
250 struct pvt *pvt = (struct pvt *)this->private; in ho_byaddr()
255 if (init(this) == -1) in ho_byaddr()
288 ho_rewind(this); in ho_byaddr()
289 while ((hp = ho_next(this)) != NULL) { in ho_byaddr()
320 ho_next(struct irs_ho *this) { in ho_next() argument
321 struct pvt *pvt = (struct pvt *)this->private; in ho_next()
326 if (init(this) == -1) in ho_next()
330 ho_rewind(this); in ho_next()
424 ho_rewind(struct irs_ho *this) { in ho_rewind() argument
425 struct pvt *pvt = (struct pvt *)this->private; in ho_rewind()
441 ho_minimize(struct irs_ho *this) { in ho_minimize() argument
442 struct pvt *pvt = (struct pvt *)this->private; in ho_minimize()
453 ho_res_get(struct irs_ho *this) { in ho_res_get() argument
454 struct pvt *pvt = (struct pvt *)this->private; in ho_res_get()
464 ho_res_set(this, res, free); in ho_res_get()
471 ho_res_set(struct irs_ho *this, struct __res_state *res, in ho_res_set() argument
473 struct pvt *pvt = (struct pvt *)this->private; in ho_res_set()
494 ho_addrinfo(struct irs_ho *this, const char *name, const struct addrinfo *pai) in ho_addrinfo() argument
496 struct pvt *pvt = (struct pvt *)this->private; in ho_addrinfo()
526 hp = (*this->byname2)(this, name, p->family); in ho_addrinfo()
563 init(struct irs_ho *this) { in init() argument
564 struct pvt *pvt = (struct pvt *)this->private; in init()
566 if (!pvt->res && !ho_res_get(this)) in init()