From e3e263b59d0cdfbc334f310d147149549c1690a3 Mon Sep 17 00:00:00 2001 From: jl777 Date: Sat, 21 Apr 2018 19:17:16 +0300 Subject: [PATCH 1/3] -print --- src/main.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main.cpp b/src/main.cpp index d243dc564..f5e14e305 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -3559,7 +3559,7 @@ CBlockIndex* AddToBlockIndex(const CBlockHeader& block) } if ( miPrev != mapBlockIndex.end() && (*miPrev).second == 0 ) { - fprintf(stderr,"edge case of both block and prevblock in the strange state\n"); + //fprintf(stderr,"edge case of both block and prevblock in the strange state\n"); return(0); // return here to avoid the state of pindex->nHeight not set and pprev NULL } } @@ -4042,7 +4042,7 @@ bool AcceptBlock(CBlock& block, CValidationState& state, CBlockIndex** ppindex, } if ( pindex == 0 ) { - fprintf(stderr,"AcceptBlock error null pindex\n"); + //fprintf(stderr,"AcceptBlock error null pindex\n"); return false; } //fprintf(stderr,"acceptblockheader passed\n"); From 1c518c38ebd240547acacb42b7926dc400840c22 Mon Sep 17 00:00:00 2001 From: ca333 Date: Sat, 21 Apr 2018 18:44:20 +0200 Subject: [PATCH 2/3] update configure win condition not needed due to boost lib fix --- configure.ac | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/configure.ac b/configure.ac index 2453930c5..7de40ff26 100644 --- a/configure.ac +++ b/configure.ac @@ -799,11 +799,7 @@ AX_CHECK_COMPILE_FLAG([-fwrapv],[CXXFLAGS="$CXXFLAGS -fwrapv"]) AX_CHECK_COMPILE_FLAG([-fno-strict-aliasing],[CXXFLAGS="$CXXFLAGS -fno-strict-aliasing"]) AX_CHECK_COMPILE_FLAG([-Wno-builtin-declaration-mismatch],[CXXFLAGS="$CXXFLAGS -Wno-builtin-declaration-mismatch"],,[[$CXXFLAG_WERROR]]) -if test x$TARGET_OS != xwindows; then - LIBZCASH_LIBS="-lgmp -lgmpxx -lboost_system -lcrypto -lsodium $RUST_LIBS" -else - LIBZCASH_LIBS="-lgmp -lgmpxx -lboost_system-mt-s -lcrypto -lsodium $RUST_LIBS" -fi +LIBZCASH_LIBS="-lgmp -lgmpxx -lboost_system -lcrypto -lsodium $RUST_LIBS" AC_MSG_CHECKING([whether to build bitcoind]) AM_CONDITIONAL([BUILD_BITCOIND], [test x$build_bitcoind = xyes]) From d859438b651b0cafb7c4bd10ad454807102034a2 Mon Sep 17 00:00:00 2001 From: jl777 Date: Sat, 21 Apr 2018 19:52:27 +0300 Subject: [PATCH 3/3] Merge --- src/main.cpp | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/main.cpp b/src/main.cpp index f5e14e305..03262b0fe 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -3550,7 +3550,6 @@ CBlockIndex* AddToBlockIndex(const CBlockHeader& block) BlockMap::iterator miPrev = mapBlockIndex.find(block.hashPrevBlock); if (it != mapBlockIndex.end()) { - //if ( ASSETCHAINS_STAKED == 0 || it->second != 0 ) // change behavior to allow komodo_ensure to work if ( it->second != 0 ) // vNodes.size() >= KOMODO_LIMITED_NETWORKSIZE, change behavior to allow komodo_ensure to work { // this is the strange case where somehow the hash is in the mapBlockIndex via as yet undetermined process, but the pindex for the hash is not there. Theoretically it is due to processing the block headers, but I have seen it get this case without having received it from the block headers or anywhere else... jl777 @@ -4162,7 +4161,6 @@ bool ProcessNewBlock(bool from_miner,int32_t height,CValidationState &state, CNo } // Store to disk CBlockIndex *pindex = NULL; - //if ( vNodes.size() < KOMODO_LIMITED_NETWORKSIZE ) //ASSETCHAINS_STAKED != 0 )// { // without the komodo_ensure call, it is quite possible to get a non-error but null pindex returned from AcceptBlockHeader. In a 2 node network, it will be a long time before that block is reprocessed. Even though restarting makes it rescan, it seems much better to keep the nodes in sync komodo_ensure(pblock,hash);