|
|
@ -47,13 +47,11 @@ def cltv_modify_tx(node, tx, prepend_scriptsig, nsequence=None, nlocktime=None):
|
|
|
|
|
|
|
|
|
|
|
|
# Need to re-sign, since nSequence and nLockTime changed
|
|
|
|
# Need to re-sign, since nSequence and nLockTime changed
|
|
|
|
signed_result = node.signrawtransactionwithwallet(ToHex(tx))
|
|
|
|
signed_result = node.signrawtransactionwithwallet(ToHex(tx))
|
|
|
|
new_tx = CTransaction()
|
|
|
|
tx = CTransaction()
|
|
|
|
new_tx.deserialize(BytesIO(hex_str_to_bytes(signed_result['hex'])))
|
|
|
|
tx.deserialize(BytesIO(hex_str_to_bytes(signed_result['hex'])))
|
|
|
|
else:
|
|
|
|
|
|
|
|
new_tx = tx
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
new_tx.vin[0].scriptSig = CScript(prepend_scriptsig + list(CScript(new_tx.vin[0].scriptSig)))
|
|
|
|
tx.vin[0].scriptSig = CScript(prepend_scriptsig + list(CScript(tx.vin[0].scriptSig)))
|
|
|
|
return new_tx
|
|
|
|
return tx
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
def cltv_invalidate(node, tx, failure_reason):
|
|
|
|
def cltv_invalidate(node, tx, failure_reason):
|
|
|
|