Lines Matching refs:hostbuf
3211 myhostname(hostbuf, size) in myhostname() argument
3212 char hostbuf[]; in myhostname()
3217 if (gethostname(hostbuf, size) < 0 || hostbuf[0] == '\0')
3218 (void) sm_strlcpy(hostbuf, "localhost", size);
3219 hp = sm_gethostbyname(hostbuf, InetMode);
3229 hp = sm_gethostbyname(hostbuf, AF_INET);
3234 if (strchr(hp->h_name, '.') != NULL || strchr(hostbuf, '.') == NULL)
3235 (void) cleanstrcpy(hostbuf, hp->h_name, size);
3238 if (strchr(hostbuf, '.') == NULL)
3245 strlen(domainname) + strlen(hostbuf) + 1 < size)
3246 (void) sm_strlcat2(hostbuf, ".", domainname, size);
3255 if (strchr(hostbuf, '.') == NULL)
3263 (void) cleanstrcpy(hostbuf, *ha, size - 1);
3264 hostbuf[size - 1] = '\0';
3279 if (strchr(hostbuf, '.') == NULL &&
3280 !getcanonname(hostbuf, size, true, NULL))
3284 hostbuf);
3286 hostbuf);
3288 if (!getcanonname(hostbuf, size, true, NULL))
3292 hostbuf);
3294 hostbuf);