mirror of
https://github.com/jwinterm/grin-wallet.git
synced 2026-10-17 15:21:39 +02:00
New contract outputs were derived with next_child(), which uses the wallet's active account. During a late-lock the active account can differ from the one the contract context was created under, so an output could be created in the wrong account. Derive under context.parent_key_id instead. - WalletBackend: add next_child_for(parent_key_id, mask); next_child delegates to it. - add_outputs_to_ctx derives via next_child_for(&context.parent_key_id, ..). - parent_key_for returns Result and errors (UnknownAccountLabel) on an unknown account name instead of silently falling back to the active account. - test: a contract referencing an unknown account now errors. Addresses PR #754 review (context.rs, utils.rs).