@ -39,6 +39,7 @@ static struct bitcoin_tx *close_tx(const tal_t *ctx,
const struct bitcoin_txid * funding_txid ,
const struct bitcoin_txid * funding_txid ,
unsigned int funding_txout ,
unsigned int funding_txout ,
struct amount_sat funding ,
struct amount_sat funding ,
const u8 * funding_wscript ,
const struct amount_sat out [ NUM_SIDES ] ,
const struct amount_sat out [ NUM_SIDES ] ,
enum side opener ,
enum side opener ,
struct amount_sat fee ,
struct amount_sat fee ,
@ -67,6 +68,7 @@ static struct bitcoin_tx *close_tx(const tal_t *ctx,
tx = create_close_tx ( ctx ,
tx = create_close_tx ( ctx ,
chainparams ,
chainparams ,
scriptpubkey [ LOCAL ] , scriptpubkey [ REMOTE ] ,
scriptpubkey [ LOCAL ] , scriptpubkey [ REMOTE ] ,
funding_wscript ,
funding_txid ,
funding_txid ,
funding_txout ,
funding_txout ,
funding ,
funding ,
@ -238,6 +240,7 @@ static void send_offer(struct per_peer_state *pps,
const struct chainparams * chainparams ,
const struct chainparams * chainparams ,
const struct channel_id * channel_id ,
const struct channel_id * channel_id ,
const struct pubkey funding_pubkey [ NUM_SIDES ] ,
const struct pubkey funding_pubkey [ NUM_SIDES ] ,
const u8 * funding_wscript ,
u8 * scriptpubkey [ NUM_SIDES ] ,
u8 * scriptpubkey [ NUM_SIDES ] ,
const struct bitcoin_txid * funding_txid ,
const struct bitcoin_txid * funding_txid ,
unsigned int funding_txout ,
unsigned int funding_txout ,
@ -262,6 +265,7 @@ static void send_offer(struct per_peer_state *pps,
funding_txid ,
funding_txid ,
funding_txout ,
funding_txout ,
funding ,
funding ,
funding_wscript ,
out ,
out ,
opener , fee_to_offer , our_dust_limit ) ;
opener , fee_to_offer , our_dust_limit ) ;
@ -371,6 +375,7 @@ receive_offer(struct per_peer_state *pps,
funding_txid ,
funding_txid ,
funding_txout ,
funding_txout ,
funding ,
funding ,
funding_wscript ,
out , opener , received_fee , our_dust_limit ) ;
out , opener , received_fee , our_dust_limit ) ;
if ( ! check_tx_sig ( tx , 0 , NULL , funding_wscript ,
if ( ! check_tx_sig ( tx , 0 , NULL , funding_wscript ,
@ -400,6 +405,7 @@ receive_offer(struct per_peer_state *pps,
funding_txid ,
funding_txid ,
funding_txout ,
funding_txout ,
funding ,
funding ,
funding_wscript ,
trimming_out ,
trimming_out ,
opener , received_fee , our_dust_limit ) ;
opener , received_fee , our_dust_limit ) ;
if ( ! trimmed
if ( ! trimmed
@ -695,7 +701,7 @@ int main(int argc, char *argv[])
for ( size_t i = 0 ; i < 2 ; i + + , whose_turn = ! whose_turn ) {
for ( size_t i = 0 ; i < 2 ; i + + , whose_turn = ! whose_turn ) {
if ( whose_turn = = LOCAL ) {
if ( whose_turn = = LOCAL ) {
send_offer ( pps , chainparams ,
send_offer ( pps , chainparams ,
& channel_id , funding_pubkey ,
& channel_id , funding_pubkey , funding_wscript ,
scriptpubkey , & funding_txid , funding_txout ,
scriptpubkey , & funding_txid , funding_txout ,
funding , out , opener ,
funding , out , opener ,
our_dust_limit ,
our_dust_limit ,
@ -744,7 +750,7 @@ int main(int argc, char *argv[])
fee_negotiation_step ,
fee_negotiation_step ,
fee_negotiation_step_unit ) ;
fee_negotiation_step_unit ) ;
send_offer ( pps , chainparams , & channel_id ,
send_offer ( pps , chainparams , & channel_id ,
funding_pubkey ,
funding_pubkey , funding_wscript ,
scriptpubkey , & funding_txid , funding_txout ,
scriptpubkey , & funding_txid , funding_txout ,
funding , out , opener ,
funding , out , opener ,
our_dust_limit ,
our_dust_limit ,