Berkeley description: An address incompatible with the
requested protocol was used. For example, you shouldn't necessarily
expect to be able to use NS addresses with ARPA Internet protocols.
WinSock description: Same as Berkeley, and then some.
The error occurs with the
function, which takes the socket type (protocol) and address family as
It also occurs with functions that take a socket handle and a
sockaddr structure as input parameters. A socket already has a type (a
protocol), and each sockaddr structure has an address family field to
define its format. A function fails with WSAEAFNOSUPPORT if the address
family referenced in sockaddr is not compatible with the referenced
This error apparently also takes the place of WSAEPFNOSUPPORT
(which means "protocol family not supported"), since that
error is not listed for in
the v1.1 WinSock specification.