mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-12-05 10:12:48 +01:00
Fix PSBT deserialization of 0-input transactions
0-input transactions can be ambiguously deserialized as being witness transactions. Since the unsigned transaction is never serialized as a witness transaction as it has no witnesses, we should always deserialize it as a non-witness transaction and set the serialization flags as such. Also always serialize the unsigned transaction as a non-witness transaction.
This commit is contained in:
@@ -61,6 +61,7 @@ public:
|
||||
|
||||
int GetVersion() const { return nVersion; }
|
||||
int GetType() const { return nType; }
|
||||
size_t size() const { return stream->size(); }
|
||||
};
|
||||
|
||||
template<typename S>
|
||||
|
||||
Reference in New Issue
Block a user