mirror of
https://github.com/aljazceru/lightning.git
synced 2025-12-20 15:44:21 +01:00
psbt-json: remove reliance on bitcoin_tx, use straight wally_psbt struct
This commit is contained in:
committed by
Christian Decker
parent
175fcf381a
commit
85dca84327
@@ -1,6 +1,7 @@
|
||||
#include <arpa/inet.h>
|
||||
#include <bitcoin/preimage.h>
|
||||
#include <bitcoin/privkey.h>
|
||||
#include <bitcoin/psbt.h>
|
||||
#include <bitcoin/pubkey.h>
|
||||
#include <bitcoin/short_channel_id.h>
|
||||
#include <ccan/ccan/str/hex/hex.h>
|
||||
@@ -242,10 +243,10 @@ void json_add_tx(struct json_stream *result,
|
||||
|
||||
void json_add_psbt(struct json_stream *stream,
|
||||
const char *fieldname,
|
||||
struct bitcoin_tx *tx)
|
||||
struct wally_psbt *psbt)
|
||||
{
|
||||
const char *psbt_b64;
|
||||
psbt_b64 = bitcoin_tx_to_psbt_base64(tx, tx);
|
||||
psbt_b64 = psbt_to_b64(NULL, psbt);
|
||||
json_add_string(stream, fieldname, take(psbt_b64));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user