SOCKADDR_STORAGE_LH structure (ws2def.h)

The SOCKADDR_STORAGE structure is a generic structure that specifies a transport address.


typedef struct sockaddr_storage {
  ADDRESS_FAMILY ss_family;
  CHAR           __ss_pad1[_SS_PAD1SIZE];
  __int64        __ss_align;
  CHAR           __ss_pad2[_SS_PAD2SIZE];



The address family for the transport address. For more information about supported address families, see WSK Address Families.


A padding of 6 bytes that puts the __ss_align member on an eight-byte boundary within the structure.


A 64-bit value that forces the structure to be 8-byte aligned.


A padding of an additional 112 bytes that brings the total size of the SOCKADDR_STORAGE structure to 128 bytes.


A WSK application typically does not directly access any of the members of the SOCKADDR_STORAGE structure except for the ss_family member. Instead, a pointer to a SOCKADDR_STORAGE structure is normally cast to a pointer to the specific SOCKADDR structure type that corresponds to a particular address family.


Minimum supported client Available in Windows Vista and later versions of the Windows operating systems.
Header ws2def.h (include Wsk.h)

See also