diff --git a/bitcoin/psbt.c b/bitcoin/psbt.c index e17237ae5..a7cabe47f 100644 --- a/bitcoin/psbt.c +++ b/bitcoin/psbt.c @@ -424,7 +424,7 @@ struct wally_psbt *psbt_from_bytes(const tal_t *ctx, const u8 *bytes, return psbt; } -void towire_psbt(u8 **pptr, const struct wally_psbt *psbt) +void towire_wally_psbt(u8 **pptr, const struct wally_psbt *psbt) { /* Let's include the PSBT bytes */ size_t bytes_written; @@ -434,8 +434,8 @@ void towire_psbt(u8 **pptr, const struct wally_psbt *psbt) tal_free(pbt_bytes); } -struct wally_psbt *fromwire_psbt(const tal_t *ctx, - const u8 **cursor, size_t *max) +struct wally_psbt *fromwire_wally_psbt(const tal_t *ctx, + const u8 **cursor, size_t *max) { struct wally_psbt *psbt; u32 psbt_byte_len; diff --git a/bitcoin/psbt.h b/bitcoin/psbt.h index 68d718f96..1282e41a2 100644 --- a/bitcoin/psbt.h +++ b/bitcoin/psbt.h @@ -70,7 +70,7 @@ const u8 *psbt_get_bytes(const tal_t *ctx, const struct wally_psbt *psbt, size_t *bytes_written); struct wally_psbt *psbt_from_bytes(const tal_t *ctx, const u8 *bytes, size_t byte_len); -void towire_psbt(u8 **pptr, const struct wally_psbt *psbt); -struct wally_psbt *fromwire_psbt(const tal_t *ctx, - const u8 **curosr, size_t *max); +void towire_wally_psbt(u8 **pptr, const struct wally_psbt *psbt); +struct wally_psbt *fromwire_wally_psbt(const tal_t *ctx, + const u8 **cursor, size_t *max); #endif /* LIGHTNING_BITCOIN_PSBT_H */ diff --git a/bitcoin/tx.c b/bitcoin/tx.c index 50f224a41..b2f558413 100644 --- a/bitcoin/tx.c +++ b/bitcoin/tx.c @@ -652,7 +652,7 @@ struct bitcoin_tx *fromwire_bitcoin_tx(const tal_t *ctx, /* pull_bitcoin_tx sets the psbt */ tal_free(tx->psbt); - tx->psbt = fromwire_psbt(tx, cursor, max); + tx->psbt = fromwire_wally_psbt(tx, cursor, max); return tx; } @@ -667,7 +667,7 @@ void towire_bitcoin_tx(u8 **pptr, const struct bitcoin_tx *tx) u8 *lin = linearize_tx(tmpctx, tx); towire_u8_array(pptr, lin, tal_count(lin)); - towire_psbt(pptr, tx->psbt); + towire_wally_psbt(pptr, tx->psbt); } struct bitcoin_tx_output *fromwire_bitcoin_tx_output(const tal_t *ctx, diff --git a/tools/generate-wire.py b/tools/generate-wire.py index f07a1800a..9714c90dc 100755 --- a/tools/generate-wire.py +++ b/tools/generate-wire.py @@ -235,6 +235,7 @@ class Type(FieldSet): 'onionmsg_path', 'route_hop', 'tx_parts', + 'wally_psbt', ] # Some BOLT types are re-typed based on their field name