com.docker.slirp: call `close` when the socket is half-closed
com.docker.slirp: call `close` when the socket is half-closed

The `Mirage_flow.proxy` code has 2 threads: 1 for each direction of
communication. When a `read` on the socket returns `0` i.e. `Eof`,
we call `TCPV4.close` to half-close the TCP/IP connection. The TCP/IP
stack will send a `FIN` but, crucially, will still allow data to be received
in the other direction until a `FIN` is received from the peer.

I believe this fixes #821

Signed-off-by: David Scott <63c9eb0ea83039690fefa11afe17873ba8278a56@docker.com>

samoht/vpnkit,djs55/vpnkit,djs55/vpnkit,djs55/vpnkit