I'm doing the following:
[...]
int res;
struct addrinfo *info;
struct addrinfo hints;
bzero(&hints, sizeof(hints));
hints.ai_flags = AI_PASSIVE;
hints.ai_socktype = SOCK_STREAM;
hints.ai_family = AF_UNSPEC;
res = getaddrinfo(ip, portname, &hints, &info);
if (res != 0) {
fprintf(stderr, "getaddrinfo failed: %s\n",
gai_strerror(res));
exit(1);
}
[...]
ip = "/var/run/something"; portname = "/local";
results in:
getaddrinfo failed: servname not supported for ai_socktype
ip = "/var/run/something"; portname = NULL;
results in:
getaddrinfo failed: No address associated with hostname
ip = "/var/run/something"; portname = NULL; hints.ai_family = AF_LOCAL
results in:
getaddrinfo failed: ai_family not supported
--
B.Walter COSMO-Project http://www.cosmo-project.de
[EMAIL PROTECTED] Usergroup [EMAIL PROTECTED]
To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-net" in the body of the message