[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[or-cvs] Bandaid workaround to make cvs not crash tor clients.



Update of /home2/or/cvsroot/tor/src/common
In directory moria:/home/arma/work/onion/cvs/tor/src/common

Modified Files:
	container.c 
Log Message:
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?


Index: container.c
===================================================================
RCS file: /home2/or/cvsroot/tor/src/common/container.c,v
retrieving revision 1.49
retrieving revision 1.50
diff -u -d -r1.49 -r1.50
--- container.c	23 Nov 2005 07:48:13 -0000	1.49
+++ container.c	25 Nov 2005 02:16:10 -0000	1.50
@@ -760,8 +760,10 @@
   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;
 }