mirror of
https://github.com/ElementsProject/lightning.git
synced 2024-11-20 02:27:51 +01:00
92b40cb68a
1. Rename channel_funding_locked to channel_funding_depth in channeld/channel_wire.csv. 2. Add minimum_depth in struct channel in common/initial_channel.h and change corresponding init function: new_initial_channel(). 3. Add confirmation_needed in struct peer in channeld/channeld.c. 4. Rename channel_tell_funding_locked to channel_tell_depth. 5. Call channel_tell_depth even if depth < minimum, and still call lockin_complete in channel_tell_depth, iff depth > minimum_depth. 6. channeld ignore the channel_funding_depth unless its > minimum_depth(except to update billboard, and set peer->confirmation_needed = minimum_depth - depth).
27 lines
759 B
C
27 lines
759 B
C
#ifndef LIGHTNING_LIGHTNINGD_CHANNEL_CONTROL_H
|
|
#define LIGHTNING_LIGHTNINGD_CHANNEL_CONTROL_H
|
|
#include "config.h"
|
|
#include <ccan/short_types/short_types.h>
|
|
#include <stdbool.h>
|
|
|
|
struct channel;
|
|
struct crypto_state;
|
|
struct lightningd;
|
|
|
|
void peer_start_channeld(struct channel *channel,
|
|
const struct crypto_state *cs,
|
|
int peer_fd, int gossip_fd,
|
|
const u8 *funding_signed,
|
|
bool reconnected);
|
|
|
|
/* Returns true if subd told, otherwise false. */
|
|
bool channel_tell_depth(struct lightningd *ld,
|
|
struct channel *channel,
|
|
const struct bitcoin_txid *txid,
|
|
u32 depth);
|
|
/* Notify channels of new blocks. */
|
|
void channel_notify_new_block(struct lightningd *ld,
|
|
u32 block_height);
|
|
|
|
#endif /* LIGHTNING_LIGHTNINGD_CHANNEL_CONTROL_H */
|