Lines Matching refs:buf

144 	u_char buf[MAXPACKET];
216 res_state res, struct hostent *hent, char *buf, size_t buflen, int *he)
239 eom = answer->buf + anslen;
260 bp = buf;
261 ep = buf + buflen;
262 cp = answer->buf;
267 n = dn_expand(answer->buf, eom, cp, bp, (int)(ep - bp));
292 n = dn_expand(answer->buf, eom, cp, bp, (int)(ep - bp));
313 n = dn_expand(answer->buf, eom, cp, tbuf,
342 n = dn_expand(answer->buf, eom, cp, tbuf,
379 n = dn_expand(answer->buf, eom, cp, bp, (int)(ep - bp));
524 gethostbyname_r(const char *name, struct hostent *hp, char *buf, int buflen,
538 res, hp, buf, buflen, he);
544 hp = gethostbyname_internal(name, AF_INET, res, hp, buf, buflen, he);
550 gethostbyname2_r(const char *name, int af, struct hostent *hp, char *buf,
559 hp = gethostbyname_internal(name, af, res, hp, buf, buflen, he);
566 struct hostent *hp, char *buf, size_t buflen, int *he)
646 info.buf = buf;
659 HENT_ARRAY(hp->h_addr_list, 1, buf, buflen);
660 HENT_ARRAY(hp->h_aliases, 0, buf, buflen);
666 if (inet_pton(af, name, buf) <= 0) {
670 hp->h_addr_list[0] = buf;
672 buf += size;
674 HENT_SCOPY(hp->h_name, name, buf, buflen);
676 map_v4v6_hostent(hp, &buf, buf + buflen);
683 struct hostent *hp, char *buf, int buflen, int *he)
730 info.buf = buf;
742 gethostent_r(FILE *hf, struct hostent *hent, char *buf, size_t buflen, int *he)
782 map_v4v6_address(buf, buf);
817 HENT_ARRAY(hent->h_addr_list, 1, buf, buflen);
819 HENT_ARRAY(hent->h_aliases, anum, buf, buflen);
820 HENT_COPY(hent->h_addr_list[0], &host_addr, hent->h_length, buf,
824 HENT_SCOPY(hent->h_name, name, buf, buflen);
828 HENT_SCOPY(hent->h_aliases[i], aliases[i], buf, buflen);
942 querybuf *buf;
967 buf = malloc(sizeof(*buf));
968 if (buf == NULL) {
974 free(buf);
978 n = res_nsearch(res, name, C_IN, type, buf->buf, (int)sizeof(buf->buf));
980 free(buf);
985 hp = getanswer(buf, n, name, type, res, info->hp, info->buf,
987 free(buf);
1007 querybuf *buf;
1048 buf = malloc(sizeof(*buf));
1049 if (buf == NULL) {
1054 free(buf);
1057 n = res_nquery(res, qbuf, C_IN, T_PTR, buf->buf, (int)sizeof(buf->buf));
1059 free(buf);
1065 hp = getanswer(buf, n, qbuf, T_PTR, res, info->hp, info->buf,
1067 free(buf);
1081 blen = (size_t)(bf - info->buf);
1208 ptr = info->buf;