Skip to content
This repository has been archived by the owner on Sep 11, 2020. It is now read-only.

Commit

Permalink
storage: filesystem, close shallow file when read
Browse files Browse the repository at this point in the history
Signed-off-by: Máximo Cuadros <[email protected]>
  • Loading branch information
mcuadros committed Apr 17, 2018
1 parent 60fd949 commit 46a247f
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions storage/filesystem/shallow.go
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@ func (s *ShallowStorage) Shallow() ([]plumbing.Hash, error) {
return nil, err
}

defer ioutil.CheckClose(f, &err)

var hash []plumbing.Hash

scn := bufio.NewScanner(f)
Expand Down

0 comments on commit 46a247f

Please sign in to comment.