aboutsummaryrefslogtreecommitdiff
path: root/src/wallet/external_signer_scriptpubkeyman.h
diff options
context:
space:
mode:
authorRyan Ofsky <ryan@ofsky.org>2023-12-13 11:43:16 -0500
committerRyan Ofsky <ryan@ofsky.org>2024-05-16 10:16:08 -0500
commit02e62c6c9af4beabaeea58fb1ea3ad0dc5094678 (patch)
tree3ddfb29afa69039b8d2444d3d2cd2e069e823aee /src/wallet/external_signer_scriptpubkeyman.h
parent0d44c44ae33434f366229c612d6edeedf7658963 (diff)
downloadbitcoin-02e62c6c9af4beabaeea58fb1ea3ad0dc5094678.tar.xz
common: Add PSBTError enum
Add separate PSBTError enum instead of reusing TransactionError enum for PSBT operations, and drop unused error codes. The error codes returned by PSBT operations and transaction broadcast functions mostly do not overlap, so using an unified enum makes it harder to call any of these functions and know which errors actually need to be handled. Define PSBTError in the common library because PSBT functionality is implemented in the common library and used by both the node (for rawtransaction RPCs) and the wallet.
Diffstat (limited to 'src/wallet/external_signer_scriptpubkeyman.h')
-rw-r--r--src/wallet/external_signer_scriptpubkeyman.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/wallet/external_signer_scriptpubkeyman.h b/src/wallet/external_signer_scriptpubkeyman.h
index 44286456b6..10d67d2ab4 100644
--- a/src/wallet/external_signer_scriptpubkeyman.h
+++ b/src/wallet/external_signer_scriptpubkeyman.h
@@ -35,7 +35,7 @@ class ExternalSignerScriptPubKeyMan : public DescriptorScriptPubKeyMan
*/
util::Result<void> DisplayAddress(const CTxDestination& dest, const ExternalSigner& signer) const;
- TransactionError FillPSBT(PartiallySignedTransaction& psbt, const PrecomputedTransactionData& txdata, int sighash_type = 1 /* SIGHASH_ALL */, bool sign = true, bool bip32derivs = false, int* n_signed = nullptr, bool finalize = true) const override;
+ std::optional<common::PSBTError> FillPSBT(PartiallySignedTransaction& psbt, const PrecomputedTransactionData& txdata, int sighash_type = 1 /* SIGHASH_ALL */, bool sign = true, bool bip32derivs = false, int* n_signed = nullptr, bool finalize = true) const override;
};
} // namespace wallet
#endif // BITCOIN_WALLET_EXTERNAL_SIGNER_SCRIPTPUBKEYMAN_H