浏览代码

fix a bootstrapping check we ignored that prevents us from running
with only one dir authority.


svn:r6570

Roger Dingledine 19 年之前
父节点
当前提交
a91be49402
共有 1 个文件被更改,包括 2 次插入4 次删除
  1. 2 4
      src/or/routerlist.c

+ 2 - 4
src/or/routerlist.c

@@ -3442,10 +3442,8 @@ update_router_descriptor_client_downloads(time_t now)
     return;
   }
 
-  /* XXX here's another magic 2 that probably should be replaced
-   * by <= smartlist_len(trusted_dir_servers)/2
-   * or by a function returning same.  -- weasel */
-  if (networkstatus_list && smartlist_len(networkstatus_list) < 2) {
+  if (networkstatus_list && smartlist_len(networkstatus_list) <=
+                            smartlist_len(trusted_dir_servers)/2) {
     log_info(LD_DIR,
              "Not enough networkstatus documents to launch requests.");
   }