aboutsummaryrefslogtreecommitdiff
path: root/src/or/router.c
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2004-11-03 18:33:07 +0000
committerNick Mathewson <nickm@torproject.org>2004-11-03 18:33:07 +0000
commit451f8b50452ae44c4319cfe55c666a45b9994e9f (patch)
treed88f565d8f7f74253af9d2a721978737b157782a /src/or/router.c
parent86ba00290b4e1f7095c1d34c46ac5b61273953be (diff)
downloadtor-451f8b50452ae44c4319cfe55c666a45b9994e9f.tar.gz
tor-451f8b50452ae44c4319cfe55c666a45b9994e9f.zip
- Implement all of control interface except authentication, setconfig,
and actually making the sockets. - Make sure that identity-based nicknames start with $. - Use new string_join interface. svn:r2661
Diffstat (limited to 'src/or/router.c')
-rw-r--r--src/or/router.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/or/router.c b/src/or/router.c
index 8b1ba1763c..989e7aed94 100644
--- a/src/or/router.c
+++ b/src/or/router.c
@@ -640,8 +640,9 @@ int router_dump_router_to_string(char *s, size_t maxlen, routerinfo_t *router,
bandwidth_usage = rep_hist_get_bandwidth_lines();
if (router->declared_family && smartlist_len(router->declared_family)) {
- char *s = smartlist_join_strings(router->declared_family, " ", 0);
- size_t n = strlen(s) + strlen("opt family ") + 2; /* 1 for \n, 1 for \0. */
+ size_t n;
+ char *s = smartlist_join_strings(router->declared_family, " ", 0, &n);
+ n += strlen("opt family ") + 2; /* 1 for \n, 1 for \0. */
family_line = tor_malloc(n);
tor_snprintf(family_line, n, "opt family %s\n", s);
tor_free(s);