@@ -26,15 +26,15 @@ static inline const CBlockIndex* GetLastBlockIndex(const CBlockIndex* pindex, co
2626 return pindex;
2727}
2828
29- static inline const CBlockIndex* GetLastBlockIndexForAlgo (const CBlockIndex* pindex, const int & algo)
29+ static inline const CBlockIndex* GetLastBlockIndexForAlgo (const CBlockIndex* pindex, const int algo)
3030{
3131 while (pindex && CBlockHeader::GetAlgoType (pindex->nVersion ) != algo && pindex->pprev ) {
3232 pindex = pindex->pprev ;
3333 }
3434 return pindex;
3535}
3636
37- static inline const CBlockIndex* GetASERTReferenceBlockForAlgo (const CBlockIndex* pindex, const int & nASERTStartHeight, const int & algo)
37+ static inline const CBlockIndex* GetASERTReferenceBlockForAlgo (const CBlockIndex* pindex, const int nASERTStartHeight, const int algo)
3838{
3939 if (!pindex)
4040 return pindex;
@@ -52,7 +52,7 @@ static inline const CBlockIndex* GetASERTReferenceBlockForAlgo(const CBlockIndex
5252
5353// Note that calling this function as part of the difficulty calculation for every block results in a time complexity of O(n^2)
5454// with respect to the number of blocks in the chain as it must count back to the reference block each time it is called while syncing
55- /* static inline const CBlockIndex* GetASERTReferenceBlockAndHeightForAlgo(const CBlockIndex* pindex, const uint32_t& nProofOfWorkLimit, const int& nASERTStartHeight, const int& algo, uint32_t& nBlocksPassed)
55+ /* static inline const CBlockIndex* GetASERTReferenceBlockAndHeightForAlgo(const CBlockIndex* pindex, const uint32_t nProofOfWorkLimit, const int nASERTStartHeight, const int algo, uint32_t& nBlocksPassed)
5656{
5757 nBlocksPassed = 1; // Account for the ASERT reference block here
5858
@@ -404,7 +404,7 @@ unsigned int AverageTargetASERT(const CBlockIndex* pindexLast, const CBlockHeade
404404 return bnNew.GetCompactRoundedBase256 ();
405405}
406406
407- bool CheckProofOfWork (const uint256& hash, const unsigned int & nBits, const int & algo, const Consensus::Params& params)
407+ bool CheckProofOfWork (const uint256& hash, const unsigned int nBits, const int algo, const Consensus::Params& params)
408408{
409409 bool fNegative ;
410410 bool fOverflow ;
0 commit comments