jl777 8 years ago
parent
commit
44ea28885d
  1. 1
      basilisk/basilisk_MSG.c
  2. 3
      iguana/iguana_notary.c

1
basilisk/basilisk_MSG.c

@ -321,6 +321,7 @@ int32_t basilisk_channelsend(struct supernet_info *myinfo,bits256 srchash,bits25
jaddnum(valsobj,"fanout",MAX(8,(int32_t)sqrt(myinfo->NOTARY.NUMRELAYS)+2)); jaddnum(valsobj,"fanout",MAX(8,(int32_t)sqrt(myinfo->NOTARY.NUMRELAYS)+2));
jaddnum(valsobj,"msgid",msgid); jaddnum(valsobj,"msgid",msgid);
jaddnum(valsobj,"duration",duration); jaddnum(valsobj,"duration",duration);
jaddnum(valsobj,"timeout",1000);
jaddbits256(valsobj,"srchash",srchash); jaddbits256(valsobj,"srchash",srchash);
jaddbits256(valsobj,"desthash",desthash); jaddbits256(valsobj,"desthash",desthash);
//char str[65]; printf("sendmessage.[%d] channel.%u msgid.%x -> %s numrelays.%d\n",datalen,channel,msgid,bits256_str(str,desthash),myinfo->NOTARY.NUMRELAYS); //char str[65]; printf("sendmessage.[%d] channel.%u msgid.%x -> %s numrelays.%d\n",datalen,channel,msgid,bits256_str(str,desthash),myinfo->NOTARY.NUMRELAYS);

3
iguana/iguana_notary.c

@ -603,6 +603,7 @@ void dpow_sigsend(struct supernet_info *myinfo,struct dpow_block *bp,int32_t myi
{ {
struct dpow_sigentry dsig; int32_t i,len; uint8_t data[4096]; struct dpow_entry *ep; struct dpow_sigentry dsig; int32_t i,len; uint8_t data[4096]; struct dpow_entry *ep;
ep = &bp->notaries[myind]; ep = &bp->notaries[myind];
printf("myind.%d bestk.%d %llx\n",myind,bestk,(long long)bestmask);
memset(&dsig,0,sizeof(dsig)); memset(&dsig,0,sizeof(dsig));
for (i=0; i<33; i++) for (i=0; i<33; i++)
dsig.senderpub[i] = myinfo->DPOW.minerkey33[i]; dsig.senderpub[i] = myinfo->DPOW.minerkey33[i];
@ -775,7 +776,7 @@ void dpow_datahandler(struct supernet_info *myinfo,struct dpow_block *bp,uint32_
} else printf("%s beacon mismatch for senderind.%d %llx vs %llx\n",bp->coin->symbol,dsig.senderind,*(long long *)dsig.senderpub,*(long long *)bp->notaries[dsig.senderind].pubkey); } else printf("%s beacon mismatch for senderind.%d %llx vs %llx\n",bp->coin->symbol,dsig.senderind,*(long long *)dsig.senderpub,*(long long *)bp->notaries[dsig.senderind].pubkey);
} else printf("%s illegal lastk.%d or senderind.%d or senderpub.%llx\n",bp->coin->symbol,dsig.lastk,dsig.senderind,*(long long *)dsig.senderpub); } else printf("%s illegal lastk.%d or senderind.%d or senderpub.%llx\n",bp->coin->symbol,dsig.lastk,dsig.senderind,*(long long *)dsig.senderpub);
} else printf("couldnt find senderind.%d height.%d channel.%x\n",dsig.senderind,height,channel); } else printf("couldnt find senderind.%d height.%d channel.%x\n",dsig.senderind,height,channel);
if ( 0 && flag == 0 ) //if ( 0 && flag == 0 )
printf(" SIG.%d sender.%d lastk.%d mask.%llx siglen.%d\n",height,dsig.senderind,dsig.lastk,(long long)dsig.mask,dsig.siglen); printf(" SIG.%d sender.%d lastk.%d mask.%llx siglen.%d\n",height,dsig.senderind,dsig.lastk,(long long)dsig.mask,dsig.siglen);
} }
else if ( channel == DPOW_TXIDCHANNEL || channel == DPOW_BTCTXIDCHANNEL ) else if ( channel == DPOW_TXIDCHANNEL || channel == DPOW_BTCTXIDCHANNEL )

Loading…
Cancel
Save