mirror of
https://github.com/golang/go
synced 2024-11-23 19:50:06 -07:00
compress/gzip: clarify behavior of Writer.Close
Fixes #20551 Change-Id: Ia47cae14a26fe5f278ad7209218d083cc50a3ff8 Reviewed-on: https://go-review.googlesource.com/44572 Reviewed-by: Ian Lance Taylor <iant@golang.org>
This commit is contained in:
parent
da1b83067d
commit
cba4b41671
@ -222,8 +222,9 @@ func (z *Writer) Flush() error {
|
||||
return z.err
|
||||
}
|
||||
|
||||
// Close closes the Writer, flushing any unwritten data to the underlying
|
||||
// io.Writer, but does not close the underlying io.Writer.
|
||||
// Close closes the Writer by flushing any unwritten data to the underlying
|
||||
// io.Writer and writing the GZIP footer.
|
||||
// It does not close the underlying io.Writer.
|
||||
func (z *Writer) Close() error {
|
||||
if z.err != nil {
|
||||
return z.err
|
||||
|
Loading…
Reference in New Issue
Block a user