diff options
author | Nick Mathewson <nickm@torproject.org> | 2017-10-31 12:19:42 -0400 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2017-10-31 12:19:42 -0400 |
commit | 4700ba6c3d67056fc271cd2355fc956c182af7ad (patch) | |
tree | 172318bc0b843c144b95cfec28bb9456220450fe /src/test/test_channelpadding.c | |
parent | 8b536ca5937911a31eaaa56b9d28f061b3d3f99f (diff) | |
parent | 652d22e608c10ee520a16fd86a4cdd90e5188025 (diff) | |
download | tor-4700ba6c3d67056fc271cd2355fc956c182af7ad.tar.gz tor-4700ba6c3d67056fc271cd2355fc956c182af7ad.zip |
Merge branch 'maint-0.3.2'
Diffstat (limited to 'src/test/test_channelpadding.c')
-rw-r--r-- | src/test/test_channelpadding.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/src/test/test_channelpadding.c b/src/test/test_channelpadding.c index fe21057c8e..4346ee343f 100644 --- a/src/test/test_channelpadding.c +++ b/src/test/test_channelpadding.c @@ -196,7 +196,8 @@ static void setup_mock_network(void) { routerstatus_t *relay; - connection_array = smartlist_new(); + if (!connection_array) + connection_array = smartlist_new(); relay1_relay2 = (channel_t*)new_fake_channeltls(2); relay1_relay2->write_cell = mock_channel_write_cell_relay1; @@ -283,7 +284,8 @@ test_channelpadding_timers(void *arg) tor_libevent_postfork(); - connection_array = smartlist_new(); + if (!connection_array) + connection_array = smartlist_new(); monotime_init(); monotime_enable_test_mocking(); @@ -573,7 +575,8 @@ test_channelpadding_consensus(void *arg) monotime_coarse_set_mock_time_nsec(1); timers_initialize(); - connection_array = smartlist_new(); + if (!connection_array) + connection_array = smartlist_new(); chan = (channel_t*)new_fake_channeltls(0); channel_timestamp_active(chan); @@ -931,7 +934,8 @@ test_channelpadding_decide_to_pad_channel(void *arg) */ channel_t *chan; int64_t new_time; - connection_array = smartlist_new(); + if (!connection_array) + connection_array = smartlist_new(); (void)arg; tor_libevent_postfork(); |