aboutsummaryrefslogtreecommitdiffstats
path: root/lib/kernel/doc/src/inet.xml
diff options
context:
space:
mode:
authorRaimo Niskanen <[email protected]>2013-11-25 14:27:40 +0100
committerRaimo Niskanen <[email protected]>2013-11-25 14:35:21 +0100
commitc4592b6941cf66cd89fb8f9664e021151dc11b8d (patch)
tree9b251bc01e00fa49279d3c3f33cb4cd83e759cd1 /lib/kernel/doc/src/inet.xml
parent01529a8de0f17acb29dfe5beaa6ad62587ed8e18 (diff)
parentb9278a19e1abdb80d93833773f4b9c431958bdcb (diff)
downloadotp-c4592b6941cf66cd89fb8f9664e021151dc11b8d.tar.gz
otp-c4592b6941cf66cd89fb8f9664e021151dc11b8d.tar.bz2
otp-c4592b6941cf66cd89fb8f9664e021151dc11b8d.zip
Merge branch 'raimo/sctp-peernames/OTP-10229' into maint-r16
* raimo/sctp-peernames/OTP-10229: Improve documentation Suppress false valgrind warnings caused by sctp_getpaddrs Document Adjust test cases for SLES 10 SP 1 Clean up address family handling towards Erlang Fix testcase indentation Fix testcases for FreeBSD 9.1 Write testcases for inet:socknames and inet:peernames Implement inet:socknames/1,2 and inet:peernames/1,2 Implement prim_inet:socknames/1,2 and prim_inet:peernames/1,2
Diffstat (limited to 'lib/kernel/doc/src/inet.xml')
-rw-r--r--lib/kernel/doc/src/inet.xml92
1 files changed, 90 insertions, 2 deletions
diff --git a/lib/kernel/doc/src/inet.xml b/lib/kernel/doc/src/inet.xml
index fd62f778a2..bc4c68230e 100644
--- a/lib/kernel/doc/src/inet.xml
+++ b/lib/kernel/doc/src/inet.xml
@@ -430,8 +430,56 @@ fe80::204:acff:fe17:bf38
<name name="peername" arity="1"/>
<fsummary>Return the address and port for the other end of a connection</fsummary>
<desc>
- <p>Returns the address and port for the other end of a
- connection.</p>
+ <p>
+ Returns the address and port for the other end of a
+ connection.
+ </p>
+ <p>
+ Note that for SCTP sockets this function only returns
+ one of the socket's peer addresses. The function
+ <seealso marker="#peernames/1">peernames/1,2</seealso>
+ returns all.
+ </p>
+ </desc>
+ </func>
+ <func>
+ <name name="peernames" arity="1"/>
+ <fsummary>
+ Return all address/port numbers for the other end of a connection
+ </fsummary>
+ <desc>
+ <p>
+ Equivalent to
+ <seealso marker="#peernames/2"><c>peernames(<anno>Socket</anno>, 0)</c></seealso>.
+ Note that this function's behaviour for an SCTP
+ one-to-many style socket is not defined by the
+ <url href="http://tools.ietf.org/html/draft-ietf-tsvwg-sctpsocket-13">SCTP Sockets API Extensions</url>.
+ </p>
+ </desc>
+ </func>
+ <func>
+ <name name="peernames" arity="2"/>
+ <fsummary>
+ Return all address/port numbers for the other end of a connection
+ </fsummary>
+ <desc>
+ <p>
+ Returns a list of all address/port number pairs for the other end
+ of a socket's association <c><anno>Assoc</anno></c>.
+ </p>
+ <p>
+ This function can return multiple addresses for multihomed
+ sockets such as SCTP sockets. For other sockets it
+ returns a one element list.
+ </p>
+ <p>
+ Note that the <c><anno>Assoc</anno></c> parameter is by the
+ <url href="http://tools.ietf.org/html/draft-ietf-tsvwg-sctpsocket-13">SCTP Sockets API Extensions</url>
+ defined to be ignored for
+ one-to-one style sockets. What the special value <c>0</c>
+ means hence its behaviour for one-to-many style sockets
+ is unfortunately not defined.
+ </p>
</desc>
</func>
<func>
@@ -446,6 +494,46 @@ fe80::204:acff:fe17:bf38
<fsummary>Return the local address and port number for a socket</fsummary>
<desc>
<p>Returns the local address and port number for a socket.</p>
+ <p>
+ Note that for SCTP sockets this function only returns
+ one of the socket addresses. The function
+ <seealso marker="#socknames/1">socknames/1,2</seealso>
+ returns all.
+ </p>
+ </desc>
+ </func>
+ <func>
+ <name name="socknames" arity="1"/>
+ <fsummary>Return all local address/port numbers for a socket</fsummary>
+ <desc>
+ <p>
+ Equivalent to
+ <seealso marker="#socknames/2"><c>socknames(<anno>Socket</anno>, 0)</c></seealso>.
+ </p>
+ </desc>
+ </func>
+ <func>
+ <name name="socknames" arity="2"/>
+ <fsummary>Return all local address/port numbers for a socket</fsummary>
+ <desc>
+ <p>
+ Returns a list of all local address/port number pairs for a socket
+ for the given association <c><anno>Assoc</anno></c>.
+ </p>
+ <p>
+ This function can return multiple addresses for multihomed
+ sockets such as SCTP sockets. For other sockets it
+ returns a one element list.
+ </p>
+ <p>
+ Note that the <c><anno>Assoc</anno></c> parameter is by the
+ <url href="http://tools.ietf.org/html/draft-ietf-tsvwg-sctpsocket-13">SCTP Sockets API Extensions</url>
+ defined to be ignored for one-to-one style sockets.
+ For one-to-many style sockets the special value <c>0</c>
+ is defined to mean that the returned addresses shall be
+ without regard to any particular association.
+ How different SCTP implementations interprets this varies somewhat.
+ </p>
</desc>
</func>
<func>