Browse Source

state: make bitcoin_commit() take a non-const peer.

We have to sign the commit at this stage, so easiest if peer isn't const
so we can sign it in-place.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
ppa-0.6.1
Rusty Russell 9 years ago
parent
commit
79e1c9bb62
  1. 3
      state.h
  2. 3
      test/test_state_coverage.c

3
state.h

@ -369,8 +369,7 @@ const struct bitcoin_tx *bitcoin_steal(const tal_t *ctx,
struct bitcoin_event *btc);
/* Create our commit tx */
const struct bitcoin_tx *bitcoin_commit(const tal_t *ctx,
const struct peer *peer);
const struct bitcoin_tx *bitcoin_commit(const tal_t *ctx, struct peer *peer);
/* Create a HTLC refund collection */
const struct bitcoin_tx *bitcoin_htlc_timeout(const tal_t *ctx,

3
test/test_state_coverage.c

@ -894,8 +894,7 @@ const struct bitcoin_tx *bitcoin_steal(const tal_t *ctx,
return bitcoin_tx("steal");
}
const struct bitcoin_tx *bitcoin_commit(const tal_t *ctx,
const struct peer *peer)
const struct bitcoin_tx *bitcoin_commit(const tal_t *ctx, struct peer *peer)
{
return bitcoin_tx("our commit");
}

Loading…
Cancel
Save