Skip to content

Commit

Permalink
Lock hyper tree when closing
Browse files Browse the repository at this point in the history
  • Loading branch information
aalda committed Feb 25, 2019
1 parent 71e0e03 commit 5c60658
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions balloon/hyper/tree.go
Original file line number Diff line number Diff line change
Expand Up @@ -151,6 +151,9 @@ func (t *HyperTree) RebuildCache() {
}

func (t *HyperTree) Close() {
t.Lock()
defer t.Unlock()

t.cache = nil
t.hasher = nil
t.defaultHashes = nil
Expand Down

0 comments on commit 5c60658

Please sign in to comment.