socket_to_stdio

Function connect_socket_to_stdio

Source
pub async fn connect_socket_to_stdio(
    socket: Socket,
    stdout: Stdout<'_>,
) -> Result<()>
Expand description

Concurrently:

  1. locks stdin and copies the input to socket
  2. reads data from socket and writes it to stdout Finishes when the remote end of the socket closes (when (2) completes).