diff options
author | Nick Mathewson <nickm@torproject.org> | 2013-01-18 12:56:47 -0500 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2013-01-30 11:58:17 -0500 |
commit | fcf906ec7335cf54050ed6d97bc1efea54a0ccfb (patch) | |
tree | 180282baf60625be8a6f8c03cf4039e9fc88c9cd /src/or/routerlist.h | |
parent | 42c4418bed2cdad029404cca39fc60f7d7235aab (diff) | |
download | tor-fcf906ec7335cf54050ed6d97bc1efea54a0ccfb.tar.gz tor-fcf906ec7335cf54050ed6d97bc1efea54a0ccfb.zip |
Add a function to compute fraction of nodes (by weighted bw) with descriptors
Diffstat (limited to 'src/or/routerlist.h')
-rw-r--r-- | src/or/routerlist.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/or/routerlist.h b/src/or/routerlist.h index 798cebc58e..1849fff31c 100644 --- a/src/or/routerlist.h +++ b/src/or/routerlist.h @@ -47,8 +47,10 @@ const routerinfo_t *routerlist_find_my_routerinfo(void); uint32_t router_get_advertised_bandwidth(const routerinfo_t *router); uint32_t router_get_advertised_bandwidth_capped(const routerinfo_t *router); -const node_t *node_sl_choose_by_bandwidth(smartlist_t *sl, +const node_t *node_sl_choose_by_bandwidth(const smartlist_t *sl, bandwidth_weight_rule_t rule); +double frac_nodes_with_descriptors(const smartlist_t *sl, + bandwidth_weight_rule_t rule); const node_t *router_choose_random_node(smartlist_t *excludedsmartlist, struct routerset_t *excludedset, |