mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-11-11 05:33:47 +01:00
Avoid dereferencing null on unit test failure for link handshakes.
This fixes CID 1301368 -- found by coverity
This commit is contained in:
parent
c03694938e
commit
a348df6d8b
@ -179,9 +179,11 @@ test_link_handshake_certs_ok(void *arg)
|
|||||||
tor_free(cell2);
|
tor_free(cell2);
|
||||||
certs_cell_free(cc1);
|
certs_cell_free(cc1);
|
||||||
certs_cell_free(cc2);
|
certs_cell_free(cc2);
|
||||||
circuitmux_free(chan1->base_.cmux);
|
if (chan1)
|
||||||
|
circuitmux_free(chan1->base_.cmux);
|
||||||
tor_free(chan1);
|
tor_free(chan1);
|
||||||
circuitmux_free(chan2->base_.cmux);
|
if (chan2)
|
||||||
|
circuitmux_free(chan2->base_.cmux);
|
||||||
tor_free(chan2);
|
tor_free(chan2);
|
||||||
crypto_pk_free(key1);
|
crypto_pk_free(key1);
|
||||||
crypto_pk_free(key2);
|
crypto_pk_free(key2);
|
||||||
|
Loading…
Reference in New Issue
Block a user