mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-09-08 19:31:18 +02:00
Clear any input_errors for an input after it is signed
Make sure that there are no errors set for an input after it is signed. This is useful for when there are multiple ScriptPubKeyMans. Some may fail to sign, but one may be able to sign, and after it does, we don't want there to be any more errors there.
This commit is contained in:
@@ -509,6 +509,9 @@ bool SignTransaction(CMutableTransaction& mtx, const SigningProvider* keystore,
|
||||
} else {
|
||||
input_errors[i] = ScriptErrorString(serror);
|
||||
}
|
||||
} else {
|
||||
// If this input succeeds, make sure there is no error set for it
|
||||
input_errors.erase(i);
|
||||
}
|
||||
}
|
||||
return input_errors.empty();
|
||||
|
Reference in New Issue
Block a user