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

[or-cvs] r17062: {tor} another coverity-found memory leak (tor/trunk/src/or)



Author: arma
Date: 2008-10-11 23:21:05 -0400 (Sat, 11 Oct 2008)
New Revision: 17062

Modified:
   tor/trunk/src/or/circuitbuild.c
Log:
another coverity-found memory leak


Modified: tor/trunk/src/or/circuitbuild.c
===================================================================
--- tor/trunk/src/or/circuitbuild.c	2008-10-12 03:19:17 UTC (rev 17061)
+++ tor/trunk/src/or/circuitbuild.c	2008-10-12 03:21:05 UTC (rev 17062)
@@ -2376,9 +2376,11 @@
     return;
   }
 
-  if (options->EntryNodes)
-    log_info(LD_CIRC,"Adding configured EntryNodes '%s'.",
-             routerset_to_string(options->EntryNodes));
+  if (options->EntryNodes) {
+    char *string = routerset_to_string(options->EntryNodes);
+    log_info(LD_CIRC,"Adding configured EntryNodes '%s'.", string);
+    tor_free(string);
+  }
 
   entry_routers = smartlist_create();
   entry_fps = smartlist_create();