forked from lthn/blockchain
currency_format_utils: added error check to lookup_acc_outs()
This commit is contained in:
parent
41a095dac9
commit
6af5dca26c
1 changed files with 2 additions and 1 deletions
|
|
@ -1595,7 +1595,8 @@ namespace currency
|
|||
bool lookup_acc_outs(const account_keys& acc, const transaction& tx, const crypto::public_key& tx_pub_key, std::vector<size_t>& outs, uint64_t& money_transfered, crypto::key_derivation& derivation)
|
||||
{
|
||||
money_transfered = 0;
|
||||
generate_key_derivation(tx_pub_key, acc.m_view_secret_key, derivation);
|
||||
bool r = generate_key_derivation(tx_pub_key, acc.m_view_secret_key, derivation);
|
||||
CHECK_AND_ASSERT_MES(r, false, "unable to generate derivation from tx_pub = " << tx_pub_key << " * view_sec, invalid tx_pub?");
|
||||
|
||||
if (is_coinbase(tx) && get_block_height(tx) == 0 && tx_pub_key == ggenesis_tx_pub_key)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue