aboutsummaryrefslogtreecommitdiff
path: root/src/or/routerlist.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/or/routerlist.c')
-rw-r--r--src/or/routerlist.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/or/routerlist.c b/src/or/routerlist.c
index 2210173f8..b6889e9ea 100644
--- a/src/or/routerlist.c
+++ b/src/or/routerlist.c
@@ -2628,6 +2628,16 @@ routerlist_free_all(void)
smartlist_free(trusted_dir_servers);
trusted_dir_servers = NULL;
}
+ if (trusted_dir_certs) {
+ DIGESTMAP_FOREACH(trusted_dir_certs, key, cert_list_t *, cl) {
+ SMARTLIST_FOREACH(cl->certs, authority_cert_t *, cert,
+ authority_cert_free(cert));
+ smartlist_free(cl->certs);
+ tor_free(cl);
+ } DIGESTMAP_FOREACH_END;
+ digestmap_free(trusted_dir_certs, NULL);
+ trusted_dir_certs = NULL;
+ }
}
/** Forget that we have issued any router-related warnings, so that we'll