Merge pull request #1493

0478ac68 blockchain: allow marking "tx not found" without an exception (moneromooo-monero)
This commit is contained in:
Riccardo Spagni 2017-01-08 16:33:41 -08:00
commit 23cf963332
No known key found for this signature in database
GPG key ID: 55432DF31CCD4FCD
5 changed files with 33 additions and 8 deletions

View file

@ -1895,11 +1895,11 @@ bool Blockchain::get_transactions(const t_ids_container& txs_ids, t_tx_container
{
try
{
txs.push_back(m_db->get_tx(tx_hash));
}
catch (const TX_DNE& e)
{
missed_txs.push_back(tx_hash);
transaction tx;
if (m_db->get_tx(tx_hash, tx))
txs.push_back(std::move(tx));
else
missed_txs.push_back(tx_hash);
}
catch (const std::exception& e)
{