aboutsummaryrefslogtreecommitdiffstats
path: root/lib/kernel/doc/src
diff options
context:
space:
mode:
authorLukas Larsson <[email protected]>2017-10-23 10:15:01 +0200
committerLukas Larsson <[email protected]>2017-10-31 10:27:13 +0100
commitc5b2a6161381951d273b124ff37a25597a27d2ef (patch)
treee8d004144de5cfeb135561dc6197010b2d559fac /lib/kernel/doc/src
parent1e1c5905d7b0db874b2df2ba838e3ab163e8f02a (diff)
downloadotp-c5b2a6161381951d273b124ff37a25597a27d2ef.tar.gz
otp-c5b2a6161381951d273b124ff37a25597a27d2ef.tar.bz2
otp-c5b2a6161381951d273b124ff37a25597a27d2ef.zip
kernel: Clarify gen_tcp:listen documentation
Diffstat (limited to 'lib/kernel/doc/src')
-rw-r--r--lib/kernel/doc/src/gen_tcp.xml7
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/kernel/doc/src/gen_tcp.xml b/lib/kernel/doc/src/gen_tcp.xml
index 070782e1f3..e6104b0c76 100644
--- a/lib/kernel/doc/src/gen_tcp.xml
+++ b/lib/kernel/doc/src/gen_tcp.xml
@@ -51,6 +51,7 @@ server() ->
{ok, Sock} = gen_tcp:accept(LSock),
{ok, Bin} = do_recv(Sock, []),
ok = gen_tcp:close(Sock),
+ ok = gen_tcp:close(LSock),
Bin.
do_recv(Sock, Bs) ->
@@ -309,9 +310,9 @@ do_recv(Sock, Bs) ->
<seealso marker="inet#setopts/2"><c>inet:setopts/2</c></seealso>.
</p></item>
</taglist>
- <p>The returned socket <c><anno>ListenSocket</anno></c> can only be
- used in calls to
- <seealso marker="#accept/1"><c>accept/1,2</c></seealso>.</p>
+ <p>The returned socket <c><anno>ListenSocket</anno></c> should be used
+ in calls to <seealso marker="#accept/1"><c>accept/1,2</c></seealso> to
+ accept incoming connection requests.</p>
<note>
<p>The default values for options specified to <c>listen</c> can
be affected by the Kernel configuration parameter