1
0
mirror of https://github.com/golang/go synced 2024-11-06 13:36:12 -07:00
go/src/compress
Joe Tsai a887579976 compress/flate: move idempotent close logic to compressor
The compressor methods already have logic for handling a sticky error.
Merge the logic from CL 136475 into that.

This slightly changes the error message to be more sensible
in the situation where it's returned by Flush.

Updates #27741

Change-Id: Ie34cf3164d0fa6bd0811175ca467dbbcb3be1395
Reviewed-on: https://go-review.googlesource.com/c/go/+/403514
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@google.com>
Run-TryBot: Ian Lance Taylor <iant@google.com>
Auto-Submit: Ian Lance Taylor <iant@google.com>
2022-05-02 21:05:53 +00:00
..
bzip2 all: replace `` and '' with “ (U+201C) and ” (U+201D) in doc comments 2022-04-05 17:52:29 +00:00
flate compress/flate: move idempotent close logic to compressor 2022-05-02 21:05:53 +00:00
gzip compress/gzip: add example of compressing reader 2022-03-15 17:59:01 +00:00
lzw all: replace `` and '' with “ (U+201C) and ” (U+201D) in doc comments 2022-04-05 17:52:29 +00:00
testdata Revert "compress: move benchmark text from src/testdata to src/compress/testdata" 2018-10-01 16:16:21 +00:00
zlib compress/zlib: tighten header CINFO check 2022-03-30 02:16:17 +00:00