util/deephash: fix sync.Pool usage

Whoops.

From yesterday's 9ae3bd0939 (not yet
used by anything, fortunately)

Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
This commit is contained in:
Brad Fitzpatrick 2021-07-05 22:20:27 -07:00
parent e0258ffd92
commit 14f901da6d
1 changed files with 1 additions and 1 deletions

View File

@ -53,7 +53,7 @@ var hasherPool = &sync.Pool{
// Hash returns the raw SHA-256 hash of v.
func Hash(v interface{}) [sha256.Size]byte {
hasher := hasherPool.Get().(*hasher)
hasherPool.Put(hasher)
defer hasherPool.Put(hasher)
return hasher.Hash(v)
}