aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorteor <teor@torproject.org>2019-02-27 15:06:39 +1000
committerteor <teor@torproject.org>2019-02-27 15:06:39 +1000
commit64e082e892a87b0565677272c412c23903f51f5c (patch)
tree07415c635286b95c59fb1375ebe65c1f63dca236
parent6c966b894c2115d18ad5aecc7d02e7b96fea1daf (diff)
parent4d9eb4dd0e67190f8e3bf5300e85611d8605400c (diff)
downloadtor-64e082e892a87b0565677272c412c23903f51f5c.tar.gz
tor-64e082e892a87b0565677272c412c23903f51f5c.zip
Merge branch 'bug29599_029' into bug29599_033
-rw-r--r--changes/bug295993
-rw-r--r--src/test/test_shared_random.c5
2 files changed, 6 insertions, 2 deletions
diff --git a/changes/bug29599 b/changes/bug29599
new file mode 100644
index 0000000000..14e2f5d077
--- /dev/null
+++ b/changes/bug29599
@@ -0,0 +1,3 @@
+ o Minor bugfixes (memory management, testing):
+ - Stop leaking parts of the shared random state in the shared-random unit
+ tests. Fixes bug 29599; bugfix on 0.2.9.1-alpha.
diff --git a/src/test/test_shared_random.c b/src/test/test_shared_random.c
index 437fc38deb..2283976415 100644
--- a/src/test/test_shared_random.c
+++ b/src/test/test_shared_random.c
@@ -686,8 +686,8 @@ test_vote(void *arg)
}
done:
- sr_commit_free(our_commit);
UNMOCK(trusteddirserver_get_by_v3_auth_digest);
+ sr_state_free();
}
static const char *sr_state_str = "Version 1\n"
@@ -921,6 +921,7 @@ test_sr_compute_srv(void *arg)
done:
UNMOCK(trusteddirserver_get_by_v3_auth_digest);
+ sr_state_free();
}
/** Return a minimal vote document with a current SRV value set to
@@ -1186,7 +1187,7 @@ test_state_transition(void *arg)
}
done:
- return;
+ sr_state_free();
}
static void