diff options
author | moneromooo-monero <moneromooo-monero@users.noreply.github.com> | 2022-08-16 20:20:38 +0000 |
---|---|---|
committer | moneromooo-monero <moneromooo-monero@users.noreply.github.com> | 2022-08-18 06:53:41 +0000 |
commit | c5579ac236962ac71cf39bd1928690fe7e1d1899 (patch) | |
tree | 00ab5fccb7d27531d611525e373d182ac09f5d9f /src/device_trezor/trezor | |
parent | wallet2: fixes for export/import output flow (diff) | |
download | monero-c5579ac236962ac71cf39bd1928690fe7e1d1899.tar.xz |
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).
Diffstat (limited to 'src/device_trezor/trezor')
-rw-r--r-- | src/device_trezor/trezor/protocol.hpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/device_trezor/trezor/protocol.hpp b/src/device_trezor/trezor/protocol.hpp index 858db1520..aa4b3a305 100644 --- a/src/device_trezor/trezor/protocol.hpp +++ b/src/device_trezor/trezor/protocol.hpp @@ -232,8 +232,8 @@ namespace tx { } const tools::wallet2::transfer_details & get_transfer(size_t idx) const { - CHECK_AND_ASSERT_THROW_MES(idx < m_unsigned_tx->transfers.second.size() + m_unsigned_tx->transfers.first && idx >= m_unsigned_tx->transfers.first, "Invalid transfer index"); - return m_unsigned_tx->transfers.second[idx - m_unsigned_tx->transfers.first]; + CHECK_AND_ASSERT_THROW_MES(idx < std::get<2>(m_unsigned_tx->transfers).size() + std::get<0>(m_unsigned_tx->transfers) && idx >= std::get<0>(m_unsigned_tx->transfers), "Invalid transfer index"); + return std::get<2>(m_unsigned_tx->transfers)[idx - std::get<0>(m_unsigned_tx->transfers)]; } const tools::wallet2::transfer_details & get_source_transfer(size_t idx) const { |