Closed ericxtang closed 5 years ago
CopyPackets returns io.EOF if we get to the end of the stream (via default assignment to err), so we should explicitly check for io.EOF in CopyFile. Otherwise we'll never get to WriteTrailer.
err
CopyPackets returns io.EOF if we get to the end of the stream (via default assignment to
err
), so we should explicitly check for io.EOF in CopyFile. Otherwise we'll never get to WriteTrailer.