Blockchain: static `prevalidate_miner_transaction`
What changed, and why it matters
This commit only adds the C++ keyword `static` to a single function declaration in a header file. It does not change what the function does, what data it can access, or how users interact with the software. There is no visible security effect.
No security action needed. If this is part of a larger refactor, review the companion implementation commit to ensure the function body no longer relies on non-static `Blockchain` state.
Security signals we found
No strong security signals were identified.
Evidence from the diff
The change marks Blockchain::prevalidate_miner_transaction as a static member function. Static member functions do not receive a this pointer and cannot access non-static members unless an instance is passed explicitly. The diff shows only the declaration in the header; the implementation is not shown, so we cannot confirm whether the body was also adjusted. On its own, this is a compile-time linkage/qualifier change with no demonstrated security impact.
Changed components
src/cryptonote_core/blockchain.hInspect captured patch +1 / −1
diff --git a/src/cryptonote_core/blockchain.h b/src/cryptonote_core/blockchain.h
index 79c1c26..4a2aafa 100644
--- a/src/cryptonote_core/blockchain.h
+++ b/src/cryptonote_core/blockchain.h
@@ -1452,7 +1452,7 @@ namespace cryptonote
*
* @return false if anything is found wrong with the miner transaction, otherwise true
*/
- bool prevalidate_miner_transaction(const block& b, uint64_t height, uint8_t hf_version);
+ static bool prevalidate_miner_transaction(const block& b, uint64_t height, uint8_t hf_version);
/**
* @brief validates a miner (coinbase) transaction
Why this scored 15/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.