fix mock blockchain; golint; bump patch

This commit is contained in:
Ian Norden 2020-08-14 14:35:08 -05:00
parent e1e392f4fb
commit a69ee0b441
3 changed files with 4 additions and 4 deletions

View File

@ -43,7 +43,7 @@ import (
"github.com/ethereum/go-ethereum/params" "github.com/ethereum/go-ethereum/params"
"github.com/ethereum/go-ethereum/rlp" "github.com/ethereum/go-ethereum/rlp"
"github.com/ethereum/go-ethereum/trie" "github.com/ethereum/go-ethereum/trie"
"github.com/hashicorp/golang-lru" lru "github.com/hashicorp/golang-lru"
) )
var ( var (
@ -2288,7 +2288,6 @@ func (bc *BlockChain) LockTrie(root common.Hash) {
bc.trieLock.Lock() bc.trieLock.Lock()
bc.lockedRoots[root] = true bc.lockedRoots[root] = true
bc.trieLock.Unlock() bc.trieLock.Unlock()
return
} }
// UnlockTrie allows dereferencing of the provided root- provided it was previously locked // UnlockTrie allows dereferencing of the provided root- provided it was previously locked
@ -2296,5 +2295,4 @@ func (bc *BlockChain) UnlockTrie(root common.Hash) {
bc.trieLock.Lock() bc.trieLock.Lock()
bc.lockedRoots[root] = false bc.lockedRoots[root] = false
bc.trieLock.Unlock() bc.trieLock.Unlock()
return
} }

View File

@ -24,7 +24,7 @@ const (
VersionMajor = 1 // Major version component of the current release VersionMajor = 1 // Major version component of the current release
VersionMinor = 9 // Minor version component of the current release VersionMinor = 9 // Minor version component of the current release
VersionPatch = 11 // Patch version component of the current release VersionPatch = 11 // Patch version component of the current release
VersionMeta = "statediff-0.0.3" // Version metadata to append to the version string VersionMeta = "statediff-0.0.4" // Version metadata to append to the version string
) )
// Version holds the textual version string. // Version holds the textual version string.

View File

@ -124,3 +124,5 @@ func (blockChain *BlockChain) SetTdByHash(hash common.Hash, td *big.Int) {
} }
blockChain.TDByHash[hash] = td blockChain.TDByHash[hash] = td
} }
func (blockChain *BlockChain) UnlockTrie(root common.Hash) {}