|
|
@ -909,7 +909,8 @@ static struct channel *wallet_stmt2channel(struct wallet *w, struct db_stmt *stm |
|
|
|
future_per_commitment_point, |
|
|
|
db_column_int(stmt, 42), |
|
|
|
db_column_int(stmt, 43), |
|
|
|
db_column_arr(tmpctx, stmt, 44, u8)); |
|
|
|
db_column_arr(tmpctx, stmt, 44, u8), |
|
|
|
db_column_int(stmt, 45)); |
|
|
|
return chan; |
|
|
|
} |
|
|
|
|
|
|
@ -980,6 +981,7 @@ static bool wallet_channels_load_active(struct wallet *w) |
|
|
|
", feerate_base" |
|
|
|
", feerate_ppm" |
|
|
|
", remote_upfront_shutdown_script" |
|
|
|
", option_static_remotekey" |
|
|
|
" FROM channels WHERE state < ?;")); |
|
|
|
db_bind_int(stmt, 0, CLOSED); |
|
|
|
db_query_prepared(stmt); |
|
|
@ -1241,7 +1243,8 @@ void wallet_channel_save(struct wallet *w, struct channel *chan) |
|
|
|
" msatoshi_to_us_max=?," |
|
|
|
" feerate_base=?," |
|
|
|
" feerate_ppm=?," |
|
|
|
" remote_upfront_shutdown_script=?" |
|
|
|
" remote_upfront_shutdown_script=?," |
|
|
|
" option_static_remotekey=?" |
|
|
|
" WHERE id=?")); |
|
|
|
db_bind_u64(stmt, 0, chan->their_shachain.id); |
|
|
|
if (chan->scid) |
|
|
@ -1288,7 +1291,8 @@ void wallet_channel_save(struct wallet *w, struct channel *chan) |
|
|
|
tal_count(chan->remote_upfront_shutdown_script)); |
|
|
|
else |
|
|
|
db_bind_null(stmt, 27); |
|
|
|
db_bind_u64(stmt, 28, chan->dbid); |
|
|
|
db_bind_int(stmt, 28, chan->option_static_remotekey); |
|
|
|
db_bind_u64(stmt, 29, chan->dbid); |
|
|
|
db_exec_prepared_v2(take(stmt)); |
|
|
|
|
|
|
|
wallet_channel_config_save(w, &chan->channel_info.their_config); |
|
|
|