diff options
author | Nick Mathewson <nickm@torproject.org> | 2014-04-26 14:48:30 -0400 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2014-04-29 12:48:02 -0400 |
commit | aa0eb2022342798fc78b2bde89d393f37c59fe78 (patch) | |
tree | 559c4913bd41265a2cbe3b07b031c90c19fabeb5 /src/test/test_routerkeys.c | |
parent | ee9ed9d817ebfb9101030ed0f899871ba8113b74 (diff) | |
download | tor-aa0eb2022342798fc78b2bde89d393f37c59fe78.tar.gz tor-aa0eb2022342798fc78b2bde89d393f37c59fe78.zip |
Fix leaks in tests related to setting options->DataDirectory
We pre-populate that value in main(), and we weren't freeing it
before overriding it.
Diffstat (limited to 'src/test/test_routerkeys.c')
-rw-r--r-- | src/test/test_routerkeys.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/test/test_routerkeys.c b/src/test/test_routerkeys.c index 1c8174b065..182e0f6f87 100644 --- a/src/test/test_routerkeys.c +++ b/src/test/test_routerkeys.c @@ -27,6 +27,7 @@ test_routerkeys_write_fingerprint(void *arg) tt_assert(key); options->ORPort_set = 1; /* So that we can get the server ID key */ + tor_free(options->DataDirectory); options->DataDirectory = tor_strdup(ddir); options->Nickname = tor_strdup("haflinger"); set_server_identity_key(key); |