diff options
Diffstat (limited to 'internal/media/png-stripper.go')
-rw-r--r-- | internal/media/png-stripper.go | 12 |
1 files changed, 0 insertions, 12 deletions
diff --git a/internal/media/png-stripper.go b/internal/media/png-stripper.go index be5e80387..79b0bac05 100644 --- a/internal/media/png-stripper.go +++ b/internal/media/png-stripper.go @@ -75,8 +75,6 @@ package media import ( "encoding/binary" - "image" - "image/png" "io" ) @@ -192,13 +190,3 @@ func (r *PNGAncillaryChunkStripper) Read(p []byte) (int, error) { } } } - -// StrippedPngDecode strips ancillary data from png to allow more lenient decoding of pngs -// see: https://github.com/golang/go/issues/43382 -// and: https://github.com/google/wuffs/blob/414a011491ff513b86d8694c5d71800f3cb5a715/script/strip-png-ancillary-chunks.go -func StrippedPngDecode(r io.Reader) (image.Image, error) { - strippedPngReader := io.Reader(&PNGAncillaryChunkStripper{ - Reader: r, - }) - return png.Decode(strippedPngReader) -} |