mirror of
https://github.com/monero-project/monero.git
synced 2025-08-15 18:40:20 -04:00
allow exporting outputs in chunks
this will make it easier huge wallets to do so without hitting random limits (eg, max string size in node).
This commit is contained in:
parent
b03d7091f7
commit
0cbf5571d3
13 changed files with 348 additions and 72 deletions
|
@ -7912,8 +7912,10 @@ bool simple_wallet::accept_loaded_tx(const std::function<size_t()> get_num_txes,
|
|||
bool simple_wallet::accept_loaded_tx(const tools::wallet2::unsigned_tx_set &txs)
|
||||
{
|
||||
std::string extra_message;
|
||||
if (!txs.transfers.second.empty())
|
||||
extra_message = (boost::format("%u outputs to import. ") % (unsigned)txs.transfers.second.size()).str();
|
||||
if (!std::get<2>(txs.new_transfers).empty())
|
||||
extra_message = (boost::format("%u outputs to import. ") % (unsigned)std::get<2>(txs.new_transfers).size()).str();
|
||||
else if (!std::get<2>(txs.transfers).empty())
|
||||
extra_message = (boost::format("%u outputs to import. ") % (unsigned)std::get<2>(txs.transfers).size()).str();
|
||||
return accept_loaded_tx([&txs](){return txs.txes.size();}, [&txs](size_t n)->const tools::wallet2::tx_construction_data&{return txs.txes[n];}, extra_message);
|
||||
}
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue