daemons: use amount_msat/amount_sat in all internal wire transfers.

As a side-effect of using amount_msat in gossipd/routing.c, we explicitly
handle overflows and don't need to pre-prune ridiculous-fee channels.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
Rusty Russell
2019-02-21 14:15:55 +10:30
parent 0d30b89043
commit 3ac0e814d0
57 changed files with 1012 additions and 800 deletions

View File

@@ -339,7 +339,7 @@ void peer_start_channeld(struct channel *channel,
&get_chainparams(ld)->genesis_blockhash,
&channel->funding_txid,
channel->funding_outnum,
channel->funding_satoshi,
channel->funding,
&channel->our_config,
&channel->channel_info.their_config,
channel->channel_info.feerate_per_kw,
@@ -354,7 +354,7 @@ void peer_start_channeld(struct channel *channel,
channel->funder,
cfg->fee_base,
cfg->fee_per_satoshi,
channel->our_msatoshi,
channel->our_msat,
&channel->local_basepoints,
&channel->local_funding_pubkey,
&ld->id,