pub async fn copy_buf<R, W>(reader: &mut R, writer: &mut W) -> Result<u64>where R: AsyncBufRead + Unpin + ?Sized, W: AsyncWrite + Unpin + ?Sized,
Copies everything a buffered reader gives into writer from the reader’s own buffer, then flushes it; answers the bytes copied.
reader
writer