core-lightning/lightningd/dual_open_control.h
niftynei 9b8909e507 dual-fund: keep track of aborted requests, seamlessly restart daemon
Clean restart of daemon after a tx-abort is a nice way to work around
the 'persistent' disconnect that we t-bast noticed.

Changelog-Fixed: `dualopend`: Fix behavior for tx-aborts. No longer hangs, appropriately continues re-init of RBF requests without reconnction msg exchange.
2023-07-30 15:20:04 +09:30

34 lines
1.0 KiB
C

#ifndef LIGHTNING_LIGHTNINGD_DUAL_OPEN_CONTROL_H
#define LIGHTNING_LIGHTNINGD_DUAL_OPEN_CONTROL_H
#include "config.h"
#include <lightningd/subd.h>
struct peer_fd;
bool peer_start_dualopend(struct peer *peer, struct peer_fd *peer_fd,
struct channel *channel);
bool peer_restart_dualopend(struct peer *peer,
struct peer_fd *peer_fd,
struct channel *channel,
bool from_abort);
void dualopen_tell_depth(struct subd *dualopend,
struct channel *channel,
const struct bitcoin_txid *txid,
u32 depth);
/* Close connection to an unsaved channel */
void channel_unsaved_close_conn(struct channel *channel, const char *why);
void json_add_unsaved_channel(struct json_stream *response,
const struct channel *channel,
/* Only set for listpeerchannels */
const struct peer *peer);
void channel_update_reserve(struct channel *channel,
struct channel_config *their_config,
struct amount_sat funding_total);
#endif /* LIGHTNING_LIGHTNINGD_DUAL_OPEN_CONTROL_H */