This commit is contained in:
jl777
2016-11-14 08:39:41 -03:00
parent 63b2d35e70
commit c246f72f13
3 changed files with 5 additions and 3 deletions

View File

@@ -17,7 +17,7 @@
#define H_KOMODO_H #define H_KOMODO_H
// Todo: // Todo:
// 0. minerids file // 0. optimize assetchains RT loop
// 1. error check fiat redeem amounts // 1. error check fiat redeem amounts
// 2. net balance limiter // 2. net balance limiter
// 3. verify: interest payment, ratification, reorgs // 3. verify: interest payment, ratification, reorgs

View File

@@ -276,7 +276,7 @@ int32_t komodo_check_deposit(int32_t height,const CBlock& block) // verify above
for (j=0; j<32; j++) for (j=0; j<32; j++)
printf("%02x",((uint8_t *)&hash)[j]); printf("%02x",((uint8_t *)&hash)[j]);
printf(" ht.%d blockhash couldnt find vout.[%d]\n",height,i); printf(" ht.%d blockhash couldnt find vout.[%d]\n",height,i);
// validate amount! // validate amount! via fiat chain
} }
} }
} }
@@ -288,7 +288,7 @@ int32_t komodo_check_deposit(int32_t height,const CBlock& block) // verify above
for (j=0; j<32; j++) for (j=0; j<32; j++)
printf("%02x",((uint8_t *)&txids[i-1])[j]); printf("%02x",((uint8_t *)&txids[i-1])[j]);
printf(" cant paxfind txid\n"); printf(" cant paxfind txid\n");
// validate amount! // validate amount! via fiat chain
} else if ( opcode == 'I' ) } else if ( opcode == 'I' )
matched++; matched++;
} }

View File

@@ -155,6 +155,8 @@ bool CheckProofOfWork(int32_t height,uint8_t *pubkey33,uint256 hash, unsigned in
} }
if (fNegative || bnTarget == 0 || fOverflow || bnTarget > UintToArith256(params.powLimit)) if (fNegative || bnTarget == 0 || fOverflow || bnTarget > UintToArith256(params.powLimit))
return error("CheckProofOfWork(): nBits below minimum work"); return error("CheckProofOfWork(): nBits below minimum work");
if ( height > 70000 )
bnTarget /= 64;
// Check proof of work matches claimed amount // Check proof of work matches claimed amount
if ( UintToArith256(hash) > bnTarget ) if ( UintToArith256(hash) > bnTarget )
{ {