Skip to main content

pump

Function pump 

Source
async fn pump<R, W>(
    conn: String,
    reader: R,
    writer: W,
    calls: UnboundedReceiver<Call>,
    keep: Box<dyn Any + Send>,
)
where R: AsyncRead + Unpin, W: AsyncWrite + Unpin + Send + 'static,
Expand description

The connection’s one task: requests out, replies back to whoever asked, until every handle is gone or the stream ends; then every call still waiting hears why, and keep (the ssh) is dropped.