Fix bug where we were returning a nil tree builder
This commit is contained in:
parent
16bf546258
commit
672491e065
|
@ -26,7 +26,10 @@ func VerifyConsistencyProof (proof ct.ConsistencyProof, first *ct.SignedTreeHead
|
|||
// nature of the tree; i.e. that the first tree is a "prefix" of the
|
||||
// second tree. If the first tree is empty, then it's trivially a prefix
|
||||
// of the second tree, so no proof is needed.
|
||||
return len(proof) == 0, nil
|
||||
if len(proof) != 0 {
|
||||
return false, nil
|
||||
}
|
||||
return true, &MerkleTreeBuilder{stack: []ct.MerkleTreeNode{}, size: 0}
|
||||
}
|
||||
// Guaranteed that 0 < first.TreeSize < second.TreeSize
|
||||
|
||||
|
|
Loading…
Reference in New Issue