From 4b77163866ed2d3706d659524da9528a06e8cb1d Mon Sep 17 00:00:00 2001 From: Dusan Klinec Date: Wed, 15 Aug 2018 23:21:24 +0200 Subject: [PATCH] xmr: simplification, do not ask to confirm change tx output - change address checked to match main address in the builder --- src/apps/monero/controller/iface.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/apps/monero/controller/iface.py b/src/apps/monero/controller/iface.py index 76acba6cc..0579b63eb 100644 --- a/src/apps/monero/controller/iface.py +++ b/src/apps/monero/controller/iface.py @@ -38,12 +38,16 @@ async def confirm_transaction(self, tsx_data, creds=None, ctx=None): from apps.monero import layout for idx, dst in enumerate(outs): + is_change = change_idx and idx == change_idx + if is_change: + continue + addr = encode_addr( net_version(creds.network_type), dst.addr.spend_public_key, dst.addr.view_public_key, ) - is_change = change_idx and idx == change_idx + await layout.require_confirm_tx( self.gctx(ctx), addr.decode("ascii"), dst.amount, is_change )