Subject: getaddrinfo
To: None <tech-net@netbsd.org>
From: Johan Danielsson <joda@pdc.kth.se>
List: tech-net
Date: 07/09/2000 00:39:02
Does, among other things, this:

static int
get_port(ai, servname, matchonly)
	struct addrinfo *ai;
	const char *servname;
	int matchonly;
{
...

	switch (ai->ai_socktype) {
	case SOCK_RAW:
		return EAI_SERVICE;
	case SOCK_DGRAM:
	case SOCK_STREAM:
		allownumeric = 1;
		break;
	case ANY:
		allownumeric = 0;
		break;
	default:
		return EAI_SOCKTYPE;
	}

...


What's so bad about using numeric services with socktype ANY?

/Johan