From c5b2a6161381951d273b124ff37a25597a27d2ef Mon Sep 17 00:00:00 2001
From: Lukas Larsson
Date: Mon, 23 Oct 2017 10:15:01 +0200
Subject: kernel: Clarify gen_tcp:listen documentation
---
lib/kernel/doc/src/gen_tcp.xml | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
(limited to 'lib/kernel')
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) ->
inet:setopts/2.
- The returned socket ListenSocket can only be
- used in calls to
- accept/1,2.
+ The returned socket ListenSocket should be used
+ in calls to accept/1,2 to
+ accept incoming connection requests.
The default values for options specified to listen can
be affected by the Kernel configuration parameter
--
cgit v1.2.3