diff --git a/ethereum/core/src/main/java/org/hyperledger/besu/ethereum/goquorum/GoQuorumBlockValidator.java b/ethereum/core/src/main/java/org/hyperledger/besu/ethereum/goquorum/GoQuorumBlockValidator.java index 0d39807458..775e869194 100644 --- a/ethereum/core/src/main/java/org/hyperledger/besu/ethereum/goquorum/GoQuorumBlockValidator.java +++ b/ethereum/core/src/main/java/org/hyperledger/besu/ethereum/goquorum/GoQuorumBlockValidator.java @@ -61,7 +61,11 @@ public class GoQuorumBlockValidator extends MainnetBlockValidator { protected Result processBlock( final ProtocolContext context, final MutableWorldState worldState, final Block block) { final MutableWorldState privateWorldState = - getPrivateWorldState(goQuorumPrivateStorage, goQuorumWorldStateArchive, block.getHeader()); + getPrivateWorldState( + goQuorumPrivateStorage, + goQuorumWorldStateArchive, + worldState.rootHash(), + block.getHash()); return ((GoQuorumBlockProcessor) blockProcessor) .processBlock(context.getBlockchain(), worldState, privateWorldState, block); diff --git a/ethereum/core/src/main/java/org/hyperledger/besu/ethereum/goquorum/GoQuorumPrivateStateUtil.java b/ethereum/core/src/main/java/org/hyperledger/besu/ethereum/goquorum/GoQuorumPrivateStateUtil.java index 5d7b32a59d..578ba6ee78 100644 --- a/ethereum/core/src/main/java/org/hyperledger/besu/ethereum/goquorum/GoQuorumPrivateStateUtil.java +++ b/ethereum/core/src/main/java/org/hyperledger/besu/ethereum/goquorum/GoQuorumPrivateStateUtil.java @@ -37,15 +37,15 @@ public class GoQuorumPrivateStateUtil { goQuorumPrivacyParameters.orElseThrow().privateStorage(); final WorldStateArchive goQuorumWorldStateArchive = goQuorumPrivacyParameters.orElseThrow().worldStateArchive(); - return getPrivateWorldState(goQuorumPrivateStorage, goQuorumWorldStateArchive, header); + return getPrivateWorldState( + goQuorumPrivateStorage, goQuorumWorldStateArchive, header.getStateRoot(), header.getHash()); } public static MutableWorldState getPrivateWorldState( final GoQuorumPrivateStorage goQuorumPrivateStorage, final WorldStateArchive goQuorumWorldStateArchive, - final BlockHeader header) { - final Hash worldStateRootHash = header.getStateRoot(); - final Hash publicBlockHash = header.getHash(); + final Hash worldStateRootHash, + final Hash publicBlockHash) { final Hash privateStateRootHash = goQuorumPrivateStorage .getPrivateStateRootHash(worldStateRootHash)