wallet: use amount_msat / amount_sat.

We change struct utxo to use amount_sat, and paper over the JSON APIs.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
Rusty Russell
2019-02-21 13:09:51 +10:30
parent 83adb94583
commit b5dcb93e5f
11 changed files with 47 additions and 30 deletions

View File

@@ -275,7 +275,7 @@ static void onchain_add_utxo(struct channel *channel, const u8 *msg)
if (!fromwire_onchain_add_utxo(msg, &u->txid, &u->outnum,
&u->close_info->commitment_point,
&u->amount, &blockheight)) {
&u->amount.satoshis, &blockheight)) {
fatal("onchaind gave invalid add_utxo message: %s", tal_hex(msg, msg));
}
u->blockheight = blockheight>0?&blockheight:NULL;