code: func NewWrapReadCloser(r io.Reader) io.ReadCloser {
  	pr, pw := io.Pipe()
  	go func() {
  		_, _ = io.Copy(pw, r)
  		pr.Close()
  		pw.Close()
  	}()
  	return &wrapReadCloser{
  		reader: pr,
  		writer: pw,
  	}
  }
docs: // NewWrapReadCloser creates a wrapReadCloser from a reader.
  // NOTE(random-liu): To avoid goroutine leakage, the reader passed in
  // must be eventually closed by the caller.