diff options
Diffstat (limited to 'man3/sockaddr-struct.3')
| -rw-r--r-- | man3/sockaddr-struct.3 | 31 |
1 files changed, 21 insertions, 10 deletions
diff --git a/man3/sockaddr-struct.3 b/man3/sockaddr-struct.3 index 9e17ceca94..de07b67765 100644 --- a/man3/sockaddr-struct.3 +++ b/man3/sockaddr-struct.3 @@ -1,6 +1,6 @@ .TH SOCKADDR 3 2022-02-24 Linux "Linux Programmer's Manual" .SH NAME -sockaddr, sockaddr_storage, sockaddr_in, sockaddr_un, socklen_t, +sockaddr, sockaddr_storage, sockaddr_in, sockaddr_in6, sockaddr_un, socklen_t, in_addr, in_addr_t, in_port_t, \- socket address .SH SYNOPSIS @@ -8,12 +8,12 @@ in_addr, in_addr_t, in_port_t, .B #include <sys/socket.h> .PP .B struct sockaddr { -.BR " sa_family_t sa_family;" " /* Address family */" -.BR " char sa_data[];" " /* Socket address */" +.BR " sa_family_t sa_family;" " /* Address family */" +.BR " char sa_data[];" " /* Socket address */" .B }; .PP .B struct sockaddr_storage { -.BR " sa_family_t ss_family;" " /* Address family */" +.BR " sa_family_t ss_family;" " /* Address family */" .B }; .PP .BR typedef " /* ... */ " socklen_t; @@ -24,9 +24,17 @@ in_addr, in_addr_t, in_port_t, .B #include <netinet/in.h> .PP .B struct sockaddr_in { -.BR " sa_family_t sin_family;" " /* " AF_INET " */" -.BR " in_port_t sin_port;" " /* Port number */" -.BR " struct in_addr sin_addr;" " /* IP address */" +.BR " sa_family_t sin_family;" " /* " AF_INET " */" +.BR " in_port_t sin_port;" " /* Port number */" +.BR " struct in_addr sin_addr;" " /* IPv4 address */" +.B }; +.PP +.B struct sockaddr_in6 { +.BR " sa_family_t sin6_family;" " /* " AF_INET6 " */" +.BR " in_port_t sin6_port;" " /* Port number */" +.BR " uint32_t sin6_flowinfo;" " /* IPv6 flow info */" +.BR " struct in6_addr sin6_addr;" " /* IPv6 address */" +.BR " uint32_t sin6_scope_id;" " /* Set of interfaces for a scope */" .B }; .PP .B struct in_addr { @@ -41,8 +49,8 @@ in_addr, in_addr_t, in_port_t, .B #include <sys/un.h> .PP .B struct sockaddr_un { -.BR " sa_family_t sun_family;" " /* Address family */" -.BR " char sun_path[];" " /* Socket pathname */" +.BR " sa_family_t sun_family;" " /* Address family */" +.BR " char sun_path[];" " /* Socket pathname */" .B }; .fi .SH DESCRIPTION @@ -67,12 +75,15 @@ this shall be an integer type of at least 32 bits. .SS Internet domain sockets .TP .I sockaddr_in -Describes an Internet domain socket address. +Describes an IPv4 Internet domain socket address. According to POSIX, the .I sin_port and .I sin_addr members shall be in network byte order. +.TP +.I sockaddr_in6 +Describes an IPv6 Internet domain socket address. .SS UNIX domain sockets .TP .I sockaddr_un |
