diff --git a/man7/unix.7 b/man7/unix.7 index 5bb8fe624..4a1b46a8f 100644 --- a/man7/unix.7 +++ b/man7/unix.7 @@ -12,7 +12,7 @@ .\" address that can appear in the sockaddr_un structure: pathname, .\" unnamed, and abstract. .\" -.TH UNIX 7 2010-09-10 "Linux" "Linux Programmer's Manual" +.TH UNIX 7 2010-10-10 "Linux" "Linux Programmer's Manual" .SH NAME unix, AF_UNIX, AF_LOCAL \- Sockets for local interprocess communication @@ -109,24 +109,26 @@ should not be inspected. an abstract socket address is distinguished by the fact that .IR sun_path[0] is a null byte ('\\0'). -All of the remaining bytes in -.I sun_path -define the "name" of the socket. +The socket's address in this namespace is given by the additional +bytes in +.IR sun_path +that are covered by the specified length of the address structure. (Null bytes in the name have no special significance.) The name has no connection with file system pathnames. -The socket's address in this namespace is given by the rest of the -bytes in -.IR sun_path . When the address of an abstract socket is returned by .BR getsockname (2), .BR getpeername (2), and .BR accept (2), -its length is -.IR "sizeof(struct sockaddr_un)" , -and -.I sun_path -contains the abstract name. +the returned +.I addrlen +is greater than +.IR "sizeof(sa_family_t)" +(i.e., greater than 2), and the name of the socket is contained in +the first +.IR "(addrlen \- sizeof(sa_family_t))" +bytes of +.IR sun_path . The abstract socket namespace is a nonportable Linux extension. .SS Socket Options For historical reasons these socket options are specified with a