Fix integer overflow errors, work around msvc parser bugs.
This commit is contained in:
parent
ce3fbbf93e
commit
fd94046eb6
2 changed files with 10 additions and 3 deletions
|
|
@ -453,7 +453,10 @@ processed_transaction database::_apply_transaction( const signed_transaction& tr
|
||||||
eval_state._sigs.reserve( trx.signatures.size() );
|
eval_state._sigs.reserve( trx.signatures.size() );
|
||||||
|
|
||||||
for( const auto& sig : trx.signatures )
|
for( const auto& sig : trx.signatures )
|
||||||
|
{
|
||||||
FC_ASSERT( eval_state._sigs.insert( std::make_pair( public_key_type(fc::ecc::public_key( sig, trx.digest() )), false) ).second, "Multiple signatures by same key detected" ) ;
|
FC_ASSERT( eval_state._sigs.insert( std::make_pair( public_key_type(fc::ecc::public_key( sig, trx.digest() )), false) ).second, "Multiple signatures by same key detected" ) ;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//If we're skipping tapos check, but not dupe check, assume all transactions have maximum expiration time.
|
//If we're skipping tapos check, but not dupe check, assume all transactions have maximum expiration time.
|
||||||
|
|
@ -531,9 +534,11 @@ processed_transaction database::_apply_transaction( const signed_transaction& tr
|
||||||
eval_state._sigs.reserve( trx.signatures.size() );
|
eval_state._sigs.reserve( trx.signatures.size() );
|
||||||
|
|
||||||
for( const auto& sig : trx.signatures )
|
for( const auto& sig : trx.signatures )
|
||||||
|
{
|
||||||
FC_ASSERT(eval_state._sigs.insert(
|
FC_ASSERT(eval_state._sigs.insert(
|
||||||
std::make_pair(public_key_type(fc::ecc::public_key(sig, trx.digest(tapos_block_summary.block_id) )),
|
std::make_pair(public_key_type(fc::ecc::public_key(sig, trx.digest(tapos_block_summary.block_id) )),
|
||||||
false)).second, "Multiple signatures by same key detected");
|
false)).second, "Multiple signatures by same key detected");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//Verify TaPoS block summary has correct ID prefix, and that this block's time is not past the expiration
|
//Verify TaPoS block summary has correct ID prefix, and that this block's time is not past the expiration
|
||||||
|
|
@ -579,7 +584,9 @@ processed_transaction database::_apply_transaction( const signed_transaction& tr
|
||||||
if( !(skip & (skip_transaction_signatures|skip_authority_check)) )
|
if( !(skip & (skip_transaction_signatures|skip_authority_check)) )
|
||||||
{
|
{
|
||||||
for( const auto& item : eval_state._sigs )
|
for( const auto& item : eval_state._sigs )
|
||||||
|
{
|
||||||
FC_ASSERT( item.second, "All signatures must be used", ("item",item) );
|
FC_ASSERT( item.second, "All signatures must be used", ("item",item) );
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return ptrx;
|
return ptrx;
|
||||||
|
|
|
||||||
|
|
@ -357,9 +357,9 @@ namespace graphene { namespace chain {
|
||||||
uint64_t account_len6_fee = 5*UINT64_C(500000000); ///< about $50
|
uint64_t account_len6_fee = 5*UINT64_C(500000000); ///< about $50
|
||||||
uint64_t account_len5_fee = 5*UINT64_C(1000000000); ///< about $100
|
uint64_t account_len5_fee = 5*UINT64_C(1000000000); ///< about $100
|
||||||
uint64_t account_len4_fee = 5*UINT64_C(2000000000); ///< about $200
|
uint64_t account_len4_fee = 5*UINT64_C(2000000000); ///< about $200
|
||||||
uint64_t account_len3_fee = 5*3000000000; ///< about $300
|
uint64_t account_len3_fee = 5*UINT64_C(3000000000); ///< about $300
|
||||||
uint64_t account_len2_fee = 5*4000000000; ///< about $400
|
uint64_t account_len2_fee = 5*UINT64_C(4000000000); ///< about $400
|
||||||
uint64_t asset_create_fee = 5ll*500000000; ///< about $35 for LTM, the cost to register the cheapest asset
|
uint64_t asset_create_fee = 5*UINT64_C(500000000); ///< about $35 for LTM, the cost to register the cheapest asset
|
||||||
uint64_t asset_update_fee = 150000; ///< the cost to modify a registered asset
|
uint64_t asset_update_fee = 150000; ///< the cost to modify a registered asset
|
||||||
uint64_t asset_issue_fee = 700000; ///< the cost to print a UIA and send it to an account
|
uint64_t asset_issue_fee = 700000; ///< the cost to print a UIA and send it to an account
|
||||||
uint64_t asset_burn_fee = 1500000; ///< the cost to burn an asset
|
uint64_t asset_burn_fee = 1500000; ///< the cost to burn an asset
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue