Commit 23ae5976 authored by Nick Mathewson's avatar Nick Mathewson 🦞
Browse files

r13254@catbus: nickm | 2007-06-04 20:13:47 -0400

 When choosing a guard, weight by bandwidth.  Resolves bug 440.


svn:r10493
parent 2e071322
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1365,7 +1365,7 @@ router_choose_random_node(const char *preferred,
    if (excludedsmartlist)
      smartlist_subtract(sl,excludedsmartlist);

    if (need_capacity)
    if (need_capacity || need_guard)
      choice = routerlist_sl_choose_by_bandwidth(sl, weight_for_exit);
    else
      choice = smartlist_choose(sl);