jl777 8 years ago
parent
commit
9fa8da1cb4
  1. 6
      iguana/dpow/dpow_network.c

6
iguana/dpow/dpow_network.c

@ -183,7 +183,7 @@ void dpow_nanoutxoset(struct dpow_nanoutxo *np,struct dpow_block *bp,int32_t isr
}
}
void dpow_ratify_update(struct supernet_info *myinfo,struct dpow_info *dp,struct dpow_block *bp,uint8_t senderind,int8_t bestk,uint64_t bestmask,uint64_t recvmask,bits256 srcutxo,uint16_t srcvout,bits256 destutxo,uint16_t destvout,uint8_t siglens[2],uint8_t sigs[2][76])
void dpow_ratify_update(struct supernet_info *myinfo,struct dpow_info *dp,struct dpow_block *bp,uint8_t senderind,int8_t bestk,uint64_t bestmask,uint64_t recvmask,bits256 srcutxo,uint16_t srcvout,bits256 destutxo,uint16_t destvout,uint8_t siglens[2],uint8_t sigs[2][76],uint32_t pendingcrcs[2])
{
int8_t bestks[64]; int32_t counts[64],i,j,numcrcs,numdiff,besti,best,bestmatches = 0,matches = 0; uint64_t masks[64],matchesmask; uint32_t crcval;
//char str[65],str2[65];
@ -194,7 +194,7 @@ void dpow_ratify_update(struct supernet_info *myinfo,struct dpow_info *dp,struct
memset(bestks,0xff,sizeof(bestks));
memset(counts,0,sizeof(counts));
for (i=0; i<2; i++)
bp->notaries[senderind].pendingcrcs[i] = np->pendingcrcs[i];
bp->notaries[senderind].pendingcrcs[i] = pendingcrcs[i];
bp->notaries[senderind].ratifysrcutxo = srcutxo;
bp->notaries[senderind].ratifysrcvout = srcvout;
bp->notaries[senderind].ratifydestutxo = destutxo;
@ -420,7 +420,7 @@ void dpow_nanoutxoget(struct supernet_info *myinfo,struct dpow_info *dp,struct d
{
if ( isratify != 0 )
{
dpow_ratify_update(myinfo,dp,bp,senderind,np->bestk,np->bestmask,np->recvmask,np->srcutxo,np->srcvout,np->destutxo,np->destvout,np->siglens,np->sigs);
dpow_ratify_update(myinfo,dp,bp,senderind,np->bestk,np->bestmask,np->recvmask,np->srcutxo,np->srcvout,np->destutxo,np->destvout,np->siglens,np->sigs,np->pendingcrcs);
}
else
{

Loading…
Cancel
Save