aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2006-01-11 04:09:40 +0000
committerNick Mathewson <nickm@torproject.org>2006-01-11 04:09:40 +0000
commitd60faa7c939017f31d73b72b782ba6782947ab72 (patch)
tree035f9cdc0122149e4d40595c233265af70a943c9
parent8907391ad60629870a2602adc5a3d171f70f789b (diff)
downloadtor-d60faa7c939017f31d73b72b782ba6782947ab72.tar.gz
tor-d60faa7c939017f31d73b72b782ba6782947ab72.zip
Fix another memleak. I love you, valgrind!
svn:r5794
-rw-r--r--src/or/config.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/or/config.c b/src/or/config.c
index b18eb50ca0..c9b021c1e8 100644
--- a/src/or/config.c
+++ b/src/or/config.c
@@ -1673,7 +1673,7 @@ config_dump(config_format_t *fmt, void *options, int minimal)
{
smartlist_t *elements;
or_options_t *defaults;
- config_line_t *line;
+ config_line_t *line, *assigned;
char *result;
int i;
const char *desc;
@@ -1702,7 +1702,7 @@ config_dump(config_format_t *fmt, void *options, int minimal)
smartlist_add(elements, tmp);
}
- line = get_assigned_option(fmt, options, fmt->vars[i].name);
+ line = assigned = get_assigned_option(fmt, options, fmt->vars[i].name);
for (; line; line = line->next) {
size_t len = strlen(line->key) + strlen(line->value) + 3;
char *tmp;
@@ -1713,7 +1713,7 @@ config_dump(config_format_t *fmt, void *options, int minimal)
}
smartlist_add(elements, tmp);
}
- config_free_lines(line);
+ config_free_lines(assigned);
}
result = smartlist_join_strings(elements, "", 0, NULL);