Fix memory leak in test_channelpadding_consensus().

The relay variable is always allocated, but might not be freed before we
return from this function.

See: Coverity CID 1437431
This commit is contained in:
Alexander Færøy 2018-06-23 12:52:04 +02:00
parent d86c45bf5c
commit 8550016e6f

View File

@ -745,6 +745,8 @@ test_channelpadding_consensus(void *arg)
tt_i64_op(val, OP_LE, 24*60*60*2);
done:
tor_free(relay);
free_mock_consensus();
free_fake_channeltls((channel_tls_t*)chan);
smartlist_free(connection_array);