diff options
author | Nick Mathewson <nickm@torproject.org> | 2014-02-11 18:10:33 -0500 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2014-02-11 18:10:33 -0500 |
commit | c3720c05fa44b3790ab0dc37e2506ee482796e21 (patch) | |
tree | 53e3146e10dbb647d13c3c64fcbe6549ff372ef0 /src/test/test_dir.c | |
parent | 10d4d3e2d58f94418ca9554aee251232bbaaab99 (diff) | |
download | tor-c3720c05fa44b3790ab0dc37e2506ee482796e21.tar.gz tor-c3720c05fa44b3790ab0dc37e2506ee482796e21.zip |
Free leakable values in the unit tests.
Thanks, Coverity! (CID 1171414, 1171415, 1171416)
Diffstat (limited to 'src/test/test_dir.c')
-rw-r--r-- | src/test/test_dir.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/test/test_dir.c b/src/test/test_dir.c index 7c625ce7dd..dcfe98dd11 100644 --- a/src/test/test_dir.c +++ b/src/test/test_dir.c @@ -1230,7 +1230,8 @@ test_a_networkstatus( vote_routerstatus_t *vrs; routerstatus_t *rs; int idx, n_rs, n_vrs; - char *v1_text=NULL, *v2_text=NULL, *v3_text=NULL, *consensus_text=NULL, *cp; + char *v1_text=NULL, *v2_text=NULL, *v3_text=NULL, *consensus_text=NULL, + *cp=NULL; smartlist_t *votes = smartlist_new(); /* For generating the two other consensuses. */ @@ -1648,6 +1649,7 @@ test_a_networkstatus( } done: + tor_free(cp); smartlist_free(votes); tor_free(v1_text); tor_free(v2_text); |