|
|
@ -1502,11 +1502,12 @@ void dpow_bestconsensus(struct dpow_block *bp) |
|
|
|
besti = i; |
|
|
|
} |
|
|
|
} |
|
|
|
if ( besti >= 0 && bestks[besti] >= 0 && masks[besti] != 0 && (recvmask & masks[besti]) == masks[besti] ) |
|
|
|
if ( best > bp->bestmatches && besti >= 0 && bestks[besti] >= 0 && masks[besti] != 0 && (recvmask & masks[besti]) == masks[besti] ) |
|
|
|
{ |
|
|
|
bp->bestmatches = best; |
|
|
|
bp->notaries[bp->myind].bestmask = bp->bestmask = masks[besti]; |
|
|
|
bp->notaries[bp->myind].bestk = bp->bestk = bestks[besti]; |
|
|
|
//printf("set best.%d to (%d %llx) recv.%llx\n",best,bp->bestk,(long long)bp->bestmask,(long long)recvmask);
|
|
|
|
printf("set best.%d to (%d %llx) recv.%llx\n",best,bp->bestk,(long long)bp->bestmask,(long long)recvmask); |
|
|
|
} |
|
|
|
bp->recvmask |= recvmask; |
|
|
|
if ( bp->bestmask == 0 )//|| (time(NULL) / 180) != bp->lastepoch )
|
|
|
@ -1904,9 +1905,9 @@ void dpow_notarize_update(struct supernet_info *myinfo,struct dpow_info *dp,stru |
|
|
|
} |
|
|
|
if ( 0 && bp->myind <= 1 ) |
|
|
|
printf("recv.%llx best.(%d %llx) m.%d p.%d:%d b.%d\n",(long long)bp->recvmask,bp->bestk,(long long)bp->bestmask,matches,paxmatches,paxbestmatches,bestmatches); |
|
|
|
if ( bestmatches >= bp->minsigs && paxbestmatches >= bp->minsigs ) |
|
|
|
if ( bestmatches >= bp->minsigs && paxbestmatches >= bp->minsigs && bp->bestk >= 0 && bp->bestmask != 0 ) |
|
|
|
{ |
|
|
|
if ( bp->pendingbestk != bp->bestk || bp->pendingbestmask != bp->bestmask ) |
|
|
|
if ( bp->pendingbestk < 0 )//bp->pendingbestk != bp->bestk || bp->pendingbestmask != bp->bestmask )
|
|
|
|
{ |
|
|
|
printf("new PENDING BESTK (%d %llx) state.%d\n",bp->bestk,(long long)bp->bestmask,bp->state); |
|
|
|
bp->pendingbestk = bp->bestk; |
|
|
|