|
@ -546,6 +546,8 @@ int32_t komodo_voutupdate(int32_t *isratificationp,int32_t notaryid,uint8_t *scr |
|
|
len += 4; |
|
|
len += 4; |
|
|
if ( ASSETCHAINS_SYMBOL[0] != 0 ) |
|
|
if ( ASSETCHAINS_SYMBOL[0] != 0 ) |
|
|
printf("[%s] ht.%d NOTARIZED.%d %s.%s %sTXID.%s lens.(%d %d)\n",ASSETCHAINS_SYMBOL,height,*notarizedheightp,ASSETCHAINS_SYMBOL[0]==0?"KMD":ASSETCHAINS_SYMBOL,kmdtxid.ToString().c_str(),ASSETCHAINS_SYMBOL[0]==0?"BTC":"KMD",desttxid.ToString().c_str(),opretlen,len); |
|
|
printf("[%s] ht.%d NOTARIZED.%d %s.%s %sTXID.%s lens.(%d %d)\n",ASSETCHAINS_SYMBOL,height,*notarizedheightp,ASSETCHAINS_SYMBOL[0]==0?"KMD":ASSETCHAINS_SYMBOL,kmdtxid.ToString().c_str(),ASSETCHAINS_SYMBOL[0]==0?"BTC":"KMD",desttxid.ToString().c_str(),opretlen,len); |
|
|
|
|
|
if ( ASSETCHAINS_SYMBOL[0] == 0 ) |
|
|
|
|
|
{ |
|
|
if ( signedfp == 0 ) |
|
|
if ( signedfp == 0 ) |
|
|
{ |
|
|
{ |
|
|
char fname[512]; |
|
|
char fname[512]; |
|
@ -560,8 +562,6 @@ int32_t komodo_voutupdate(int32_t *isratificationp,int32_t notaryid,uint8_t *scr |
|
|
fwrite(&signedmask,1,sizeof(signedmask),signedfp); |
|
|
fwrite(&signedmask,1,sizeof(signedmask),signedfp); |
|
|
fflush(signedfp); |
|
|
fflush(signedfp); |
|
|
} |
|
|
} |
|
|
if ( ASSETCHAINS_SYMBOL[0] == 0 ) |
|
|
|
|
|
{ |
|
|
|
|
|
if ( opretlen > len && scriptbuf[len] == 'A' ) |
|
|
if ( opretlen > len && scriptbuf[len] == 'A' ) |
|
|
{ |
|
|
{ |
|
|
//for (i=0; i<opretlen-len; i++)
|
|
|
//for (i=0; i<opretlen-len; i++)
|
|
@ -692,8 +692,25 @@ void komodo_connectblock(CBlockIndex *pindex,CBlock& block) |
|
|
(numvalid >= KOMODO_MINRATIFY && ASSETCHAINS_SYMBOL[0] != 0) || |
|
|
(numvalid >= KOMODO_MINRATIFY && ASSETCHAINS_SYMBOL[0] != 0) || |
|
|
numvalid > (numnotaries/5)) ) |
|
|
numvalid > (numnotaries/5)) ) |
|
|
{ |
|
|
{ |
|
|
if ( height > 500000 || ASSETCHAINS_SYMBOL[0] != 0 ) |
|
|
if ( ASSETCHAINS_SYMBOL[0] != 0 ) |
|
|
|
|
|
{ |
|
|
|
|
|
static FILE *signedfp; |
|
|
|
|
|
if ( signedfp == 0 ) |
|
|
|
|
|
{ |
|
|
|
|
|
char fname[512]; |
|
|
|
|
|
komodo_statefname(fname,ASSETCHAINS_SYMBOL,(char *)"signedmasks"); |
|
|
|
|
|
if ( (signedfp= fopen(fname,"rb+")) == 0 ) |
|
|
|
|
|
signedfp = fopen(fname,"wb"); |
|
|
|
|
|
else fseek(signedfp,0,SEEK_END); |
|
|
|
|
|
} |
|
|
|
|
|
if ( signedfp != 0 ) |
|
|
|
|
|
{ |
|
|
|
|
|
fwrite(&height,1,sizeof(height),signedfp); |
|
|
|
|
|
fwrite(&signedmask,1,sizeof(signedmask),signedfp); |
|
|
|
|
|
fflush(signedfp); |
|
|
|
|
|
} |
|
|
printf("[%s] ht.%d txi.%d signedmask.%llx numvins.%d numvouts.%d <<<<<<<<<<< notarized\n",ASSETCHAINS_SYMBOL,height,i,(long long)signedmask,numvins,numvouts); |
|
|
printf("[%s] ht.%d txi.%d signedmask.%llx numvins.%d numvouts.%d <<<<<<<<<<< notarized\n",ASSETCHAINS_SYMBOL,height,i,(long long)signedmask,numvins,numvouts); |
|
|
|
|
|
} |
|
|
notarized = 1; |
|
|
notarized = 1; |
|
|
} |
|
|
} |
|
|
if ( NOTARY_PUBKEY33[0] != 0 && ASSETCHAINS_SYMBOL[0] == 0 ) |
|
|
if ( NOTARY_PUBKEY33[0] != 0 && ASSETCHAINS_SYMBOL[0] == 0 ) |
|
|