Winsock error 10041

WSAEPROTOTYPE  -  Protocol wrong type for socket.

Basic (Microsoft) information for 10041 a.k.a. WSAEPROTOTYPE

A protocol was specified in the socket function call that does not support the semantics of the socket type requested. For example, the ARPA Internet UDP protocol cannot be specified with a socket type of SOCK_STREAM.

Detailed (Berkeley) information for winsock 10041, described as "Protocol wrong type for socket."

Berkeley description: A protocol was specified that does not support the semantics of the socket type requested. For example, you cannot use the ARPA Internet UDP protocol with type SOCK_STREAM.

WinSock description: Same as Berkeley. This error occurs if you specifically reference a protocol that isn't part of the address family you also reference. The only function that takes these two explicit parameters is.

Developer suggestions: Since there're only one corresponding protocol for each of the datagram and datastream socket types in the Internet address family, you should simply leave the value in the protocol input parameter to. Alternately, you could call or to get the appropriate protocol value from the network system.

 

[Home] [Full list of Winsock Error codes]
[Peer Monitor - network monitoring tool] [DanielClarke.com] [Hungarian language course]