From 513ebc5bb4c6a1edb5e199aa6f1aa5fe4947f04b Mon Sep 17 00:00:00 2001 From: Duke Date: Wed, 19 Apr 2023 11:01:20 -0400 Subject: [PATCH] Say which height we are at when we get an assertion from GetBlockHash --- src/chain.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/chain.h b/src/chain.h index 03d3b3be2..46136df99 100644 --- a/src/chain.h +++ b/src/chain.h @@ -512,7 +512,10 @@ public: uint256 GetBlockHash() const { - assert(phashBlock); + if(phashBlock == NULL) { + fprintf(stderr, "GetBlockHash: phashBlock NULL at height %d\n", this->GetHeight()); + assert(phashBlock); + } return *phashBlock; }