Skip to content

Commit

Permalink
ignore extraneous warning
Browse files Browse the repository at this point in the history
  • Loading branch information
pjdufour committed Oct 11, 2018
1 parent 6a4ece2 commit 2a1f013
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion grw/Reader.go
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,8 @@ func (r *Reader) Close() error {
func (r *Reader) ReadAllAndClose() ([]byte, error) {
b, err := ioutil.ReadAll(r.Reader)
if err != nil {
r.Close()
// Attempt to close even if there is an error while reading
r.Close() // #nosec
return b, err
}
err = r.Close()
Expand Down

0 comments on commit 2a1f013

Please sign in to comment.