summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2004-11-09 17:14:15 +0000
committerNick Mathewson <nickm@torproject.org>2004-11-09 17:14:15 +0000
commita2079c074f9634a2eeed564d2514b547ab0a0b6b (patch)
treef8244c07d03223352f4360bbfc77bec350591951
parent548d4174ef7449fc32e9a4ae993a3d13f9e45fe6 (diff)
downloadtor-a2079c074f9634a2eeed564d2514b547ab0a0b6b.tar.gz
tor-a2079c074f9634a2eeed564d2514b547ab0a0b6b.zip
Add some documentation to routerlist
svn:r2753
-rw-r--r--src/or/routerlist.c17
1 files changed, 11 insertions, 6 deletions
diff --git a/src/or/routerlist.c b/src/or/routerlist.c
index f74ac0ae9b..7506da267e 100644
--- a/src/or/routerlist.c
+++ b/src/or/routerlist.c
@@ -1170,22 +1170,27 @@ int routers_update_status_from_entry(smartlist_t *routers,
return 0;
}
-int router_update_status_from_smartlist(routerinfo_t *router,
- time_t list_time,
- smartlist_t *running_list,
- int rr_format)
+/** As router_update_status_from_entry, but consider all entries in
+ * running_list. */
+int
+router_update_status_from_smartlist(routerinfo_t *router,
+ time_t list_time,
+ smartlist_t *running_list,
+ int rr_format)
{
smartlist_t *rl;
rl = smartlist_create();
smartlist_add(rl,router);
SMARTLIST_FOREACH(running_list, const char *, cp,
routers_update_status_from_entry(rl,list_time,cp,rr_format));
-
smartlist_free(rl);
return 0;
}
-void add_trusted_dir_server(const char *address, uint16_t port, const char *digest)
+/** Add to the list of authorized directory servers one at
+ * <b>address</b>:<b>port</b>, with identity key <b>digest</b>. */
+void
+add_trusted_dir_server(const char *address, uint16_t port, const char *digest)
{
trusted_dir_server_t *ent;
uint32_t a;