s6

Mirror/fork of https://skarnet.org/software/s6/
git clone https://ccx.te2000.cz/git/s6
Log | Files | Refs | README | LICENSE

commit 47e886410b0e1e9e2f40a3447d6a9a9c1c07928f
parent c7f5b86a804ae16ab3a4bcda9593a49bce81791c
Author: Laurent Bercot <ska-skaware@skarnet.org>
Date:   Thu,  9 Feb 2023 16:35:44 +0000

 Clarify the use of shutdown() in s6-ioconnect

Signed-off-by: Laurent Bercot <ska@appnovation.com>

Diffstat:
Mdoc/s6-ioconnect.html | 11+++++++++++
1 file changed, 11 insertions(+), 0 deletions(-)

diff --git a/doc/s6-ioconnect.html b/doc/s6-ioconnect.html @@ -73,6 +73,17 @@ suite, which is why the examples here involve TCP. Nevertheless, it can be used with connections across Unix domain sockets as well, and has its place in the s6 package. </li> + <li> If one of the endpoints is a socket, s6-ioconnect will call +<a href="https://pubs.opengroup.org/onlinepubs/9699919799/functions/shutdown.html">shutdown()</a> +on it (for reading or writing, depending on the endpoint) when it +needs to transmit EOF. This is a necessary workaround to a +<a href="https://cr.yp.to/tcpip/twofd.html">misdesign</a> of the +socket API, but it could have unintended consequences +when the socket is shared among several processes that expect a +persistent connection. Most of the time, however, it is a mistake +to share a data socket between processes, so s6-ioconnect's behaviour +is suited to an overwhelming majority of cases, and the exceptions are +specialized enough that they won't need to use s6-ioconnect. </li> </ul> </body>