Box big Transaction type in psbt error

This commit is contained in:
Riccardo Casatta 2020-11-18 10:33:36 +01:00
parent 9b2098517e
commit 781b0e014a
No known key found for this signature in database
GPG Key ID: FD986A969E450397
2 changed files with 4 additions and 4 deletions

View File

@ -55,9 +55,9 @@ pub enum Error {
/// transaction.
UnexpectedUnsignedTx {
/// Expected
expected: Transaction,
expected: Box<Transaction>,
/// Actual
actual: Transaction,
actual: Box<Transaction>,
},
/// Unable to parse as a standard SigHash type.
NonStandardSigHashType(u32),

View File

@ -169,8 +169,8 @@ impl Map for Global {
fn merge(&mut self, other: Self) -> Result<(), psbt::Error> {
if self.unsigned_tx != other.unsigned_tx {
return Err(psbt::Error::UnexpectedUnsignedTx {
expected: self.unsigned_tx.clone(),
actual: other.unsigned_tx,
expected: Box::new(self.unsigned_tx.clone()),
actual: Box::new(other.unsigned_tx),
});
}