diff --git a/src/cc/marmara.cpp b/src/cc/marmara.cpp index 359092ef9..908e3557d 100644 --- a/src/cc/marmara.cpp +++ b/src/cc/marmara.cpp @@ -116,9 +116,18 @@ int32_t MarmaraValidateCoinbase(int32_t height,CTransaction tx) { struct CCcontract_info *cp,C; CPubKey pk; int32_t ht,unlockht; CTxOut ccvout; cp = CCinit(&C,EVAL_MARMARA); - for (ht=0; ht<10000; ht+=MARMARA_GROUPSIZE/3) - fprintf(stderr,"%d ",MarmaraUnlockht(ht)); - fprintf(stderr,"<- unlock hts\n"); + int32_t d,histo[365*2]; + for (ht=2; ht<1000000; ht+=MARMARA_GROUPSIZE) + { + memset(histo,0,sizeof(histo)); + d = (MarmaraUnlockht(ht) - ht) / 1440 + if ( d < 0 || d > sizeof(histo)/sizeof(*histo) ) + fprintf(stderr,"d error.%d at ht.%d\n",d,ht); + else histo[d]++; + } + for (ht=0; ht