Winsock Error Codes - Brought to you by Winsock-Error.com

10048 "Address already in use."

WSAEADDRINUSE (Winsock error number: 10048)

Microsoft say this about Winsock error 10048 - WSAEADDRINUSE:

Typically, only one usage of each socket address (protocol/IP address/port) is permitted. This error occurs if an application attempts to bind a socket to an IP address/port that has already been used for an existing socket, or a socket that was not closed properly, or one that is still in the process of closing. For server applications that need to bind multiple sockets to the same port number, consider using setsockopt (SO_REUSEADDR). Client applications usually need not call bind at all— connect chooses an unused port automatically. When bind is called with a wildcard address (involving ADDR_ANY), a WSAEADDRINUSE error could be delayed until the specific address is committed. This could happen with a call to another function later, including connect, listen, WSAConnect, or WSAJoinLeaf.

Full details of Winsock TCP error 10048 - WSAEADDRINUSE:

Berkeley description: Only one usage of each address is normally permitted.

WinSock description: Same as Berkeley. The "address" they refer to, typically refers to the local "socket name", which is made up of the 3-tuple: protocol, port-number and IP address.

   
This page is designed to help you to understand Winsock TCP error 10048. It will not necessarily mean you can instantly fix issues when your computer tells you that Winsock is having problems with code 10048, rather it will give you the necessary background information to help solve the matter.

Programming declarations for 10048 (WSAEADDRINUSE):

C#
long WSAEADDRINUSE = 10048 ;

VB.net
Dim WSAEADDRINUSE As Long = 10048

VB6
Dim WSAEADDRINUSE As Long
WSAEADDRINUSE = 10048