Mark unused parameters as such (using "UNUSED")

This commit is contained in:
practicalswift 2018-03-05 17:40:50 +01:00 committed by Rusty Russell
parent 20ae038080
commit 03e2e404f2
5 changed files with 13 additions and 13 deletions

View file

@ -86,7 +86,7 @@ static struct half_chan *add_connection(struct routing_state *rstate,
/* Returns chan connecting from and to: *idx set to refer /* Returns chan connecting from and to: *idx set to refer
* to connection with src=from, dst=to */ * to connection with src=from, dst=to */
static struct chan *find_channel(struct routing_state *rstate, static struct chan *find_channel(struct routing_state *rstate UNUSED,
const struct node *from, const struct node *from,
const struct node *to, const struct node *to,
int *idx) int *idx)

View file

@ -112,7 +112,7 @@ static void peer_closing_complete(struct channel *channel, const u8 *msg)
channel_set_state(channel, CLOSINGD_SIGEXCHANGE, CLOSINGD_COMPLETE); channel_set_state(channel, CLOSINGD_SIGEXCHANGE, CLOSINGD_COMPLETE);
} }
static unsigned closing_msg(struct subd *sd, const u8 *msg, const int *fds) static unsigned closing_msg(struct subd *sd, const u8 *msg, const int *fds UNUSED)
{ {
enum closing_wire_type t = fromwire_peektype(msg); enum closing_wire_type t = fromwire_peektype(msg);

View file

@ -240,7 +240,7 @@ static void onchain_add_utxo(struct channel *channel, const u8 *msg)
wallet_add_utxo(channel->peer->ld->wallet, u, p2wpkh); wallet_add_utxo(channel->peer->ld->wallet, u, p2wpkh);
} }
static unsigned int onchain_msg(struct subd *sd, const u8 *msg, const int *fds) static unsigned int onchain_msg(struct subd *sd, const u8 *msg, const int *fds UNUSED)
{ {
enum onchain_wire_type t = fromwire_peektype(msg); enum onchain_wire_type t = fromwire_peektype(msg);
@ -324,12 +324,12 @@ static bool tell_if_missing(const struct channel *channel,
/* Only error onchaind can get is if it dies. */ /* Only error onchaind can get is if it dies. */
static void onchain_error(struct channel *channel, static void onchain_error(struct channel *channel,
int peer_fd, int gossip_fd, int peer_fd UNUSED, int gossip_fd UNUSED,
const struct crypto_state *cs, const struct crypto_state *cs UNUSED,
u64 gossip_index, u64 gossip_index UNUSED,
const struct channel_id *channel_id, const struct channel_id *channel_id UNUSED,
const char *desc, const char *desc,
const u8 *err_for_them) const u8 *err_for_them UNUSED)
{ {
/* FIXME: re-launch? */ /* FIXME: re-launch? */
log_broken(channel->log, "%s", desc); log_broken(channel->log, "%s", desc);
@ -341,7 +341,7 @@ static void onchain_error(struct channel *channel,
* onchaind (like any other owner), and restart */ * onchaind (like any other owner), and restart */
enum watch_result funding_spent(struct channel *channel, enum watch_result funding_spent(struct channel *channel,
const struct bitcoin_tx *tx, const struct bitcoin_tx *tx,
size_t input_num, size_t input_num UNUSED,
const struct block *block) const struct block *block)
{ {
u8 *msg; u8 *msg;

View file

@ -484,7 +484,7 @@ static void opening_channel_errmsg(struct uncommitted_channel *uc,
int peer_fd, int gossip_fd, int peer_fd, int gossip_fd,
const struct crypto_state *cs, const struct crypto_state *cs,
u64 gossip_index, u64 gossip_index,
const struct channel_id *channel_id, const struct channel_id *channel_id UNUSED,
const char *desc, const char *desc,
const u8 *err_for_them) const u8 *err_for_them)
{ {
@ -616,7 +616,7 @@ u8 *peer_accept_channel(struct lightningd *ld,
const struct wireaddr *addr, const struct wireaddr *addr,
const struct crypto_state *cs, const struct crypto_state *cs,
u64 gossip_index, u64 gossip_index,
const u8 *gfeatures, const u8 *lfeatures, const u8 *gfeatures UNUSED, const u8 *lfeatures UNUSED,
int peer_fd, int gossip_fd, int peer_fd, int gossip_fd,
const struct channel_id *channel_id, const struct channel_id *channel_id,
const u8 *open_msg) const u8 *open_msg)
@ -698,7 +698,7 @@ static void peer_offer_channel(struct lightningd *ld,
const struct wireaddr *addr, const struct wireaddr *addr,
const struct crypto_state *cs, const struct crypto_state *cs,
u64 gossip_index, u64 gossip_index,
const u8 *gfeatures, const u8 *lfeatures, const u8 *gfeatures UNUSED, const u8 *lfeatures UNUSED,
int peer_fd, int gossip_fd) int peer_fd, int gossip_fd)
{ {
u8 *msg; u8 *msg;

View file

@ -410,7 +410,7 @@ bool invoices_iterate(struct invoices *invoices,
} }
} }
void invoices_iterator_deref(const tal_t *ctx, void invoices_iterator_deref(const tal_t *ctx,
struct invoices *invoices, struct invoices *invoices UNUSED,
const struct invoice_iterator *it, const struct invoice_iterator *it,
struct invoice_details *details) struct invoice_details *details)
{ {