Lines Matching refs:hptr
41 gethostbyname_r(const char *name, struct hostent *hptr, HOST_R_ARGS) {
52 if (he == NULL || (n = copy_hostent(he, hptr, HOST_R_COPY)) != 0)
55 *answerp = hptr;
62 return (copy_hostent(he, hptr, HOST_R_COPY));
68 struct hostent *hptr, HOST_R_ARGS) {
79 if (he == NULL || (n = copy_hostent(he, hptr, HOST_R_COPY)) != 0)
82 *answerp = hptr;
89 return (copy_hostent(he, hptr, HOST_R_COPY));
100 gethostent_r(struct hostent *hptr, HOST_R_ARGS) {
111 if (he == NULL || (n = copy_hostent(he, hptr, HOST_R_COPY)) != 0)
114 *answerp = hptr;
121 return (copy_hostent(he, hptr, HOST_R_COPY));
159 copy_hostent(struct hostent *he, struct hostent *hptr, HOST_R_COPY_ARGS) {
183 hptr->h_addrtype = he->h_addrtype;
184 n = hptr->h_length = he->h_length;
190 hptr->h_addr_list = ptr;
193 hptr->h_addr_list[i] = cp;
196 hptr->h_addr_list[i] = NULL;
202 hptr->h_name = cp;
206 hptr->h_aliases = ptr;
210 hptr->h_aliases[i] = cp;
213 hptr->h_aliases[i] = NULL;
219 copy_hostent(struct hostent *he, struct hostent *hptr, HOST_R_COPY_ARGS) {
224 hptr->h_addrtype = he->h_addrtype;
225 n = hptr->h_length = he->h_length;
231 hptr->h_addr_list = hdptr->h_addr_ptrs;
235 hptr->h_addr_list[i] = cp;
242 hptr->h_addr_list[i] = NULL;
247 hptr->h_name = cp;
255 hptr->h_aliases = hdptr->host_aliases;
259 hptr->h_aliases[i] = cp;
266 hptr->h_aliases[i] = NULL;