openingd: don't leak peer messages.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
Rusty Russell 2018-08-24 16:37:13 +09:30 committed by Christian Decker
parent 36e31cacf9
commit 11a1ec6e94
1 changed files with 1 additions and 1 deletions

View File

@ -951,7 +951,7 @@ static u8 *fundee_channel(struct state *state, const u8 *open_channel_msg)
static u8 *handle_peer_in(struct state *state)
{
u8 *msg = sync_crypto_read(NULL, &state->cs, PEER_FD);
u8 *msg = sync_crypto_read(tmpctx, &state->cs, PEER_FD);
enum wire_type t = fromwire_peektype(msg);
struct channel_id channel_id;