aboutsummaryrefslogtreecommitdiff
path: root/src/common/container.c
diff options
context:
space:
mode:
authorRoger Dingledine <arma@torproject.org>2005-11-25 02:16:10 +0000
committerRoger Dingledine <arma@torproject.org>2005-11-25 02:16:10 +0000
commitb6b1b4f2838addea9cc9d650b6b1ee27ed42ea88 (patch)
tree22d759d7ff9c76ee8c30892b42e8487b5f3c91ec /src/common/container.c
parent2350e487a223b9137b3f53181ff7beca030b6f54 (diff)
downloadtor-b6b1b4f2838addea9cc9d650b6b1ee27ed42ea88.tar.gz
tor-b6b1b4f2838addea9cc9d650b6b1ee27ed42ea88.zip
Bandaid workaround to make cvs not crash tor clients.
This is not a real fix. I didn't look at the rest of the code. Nick? svn:r5455
Diffstat (limited to 'src/common/container.c')
-rw-r--r--src/common/container.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/common/container.c b/src/common/container.c
index b5bb6cd0bf..d34299254f 100644
--- a/src/common/container.c
+++ b/src/common/container.c
@@ -760,8 +760,10 @@ strmap_iter_next_rmv(strmap_t *map, strmap_iter_t *iter)
tor_assert(map);
tor_assert(iter);
next = HT_NEXT_RMV(strmap_tree, &map->head, iter);
- tor_free((*iter)->key);
- tor_free(*iter);
+ if (*iter) {
+ tor_free((*iter)->key);
+ tor_free(*iter);
+ }
return next;
}