Browse Source

Add a ! to directory_caches_dir_info() to fix a logic error

We want to fetch directory info more aggressively if we need it to
refuseunknownexits.  Thus, we'll want it if our exit policy is _NOT_
reject *.
Nick Mathewson 15 years ago
parent
commit
2849a95691
2 changed files with 6 additions and 1 deletions
  1. 5 0
      changes/caches_if_exit
  2. 1 1
      src/or/dirserv.c

+ 5 - 0
changes/caches_if_exit

@@ -0,0 +1,5 @@
+  o Minor bugfixes:
+    - Fix a logic error where servers that _didn't_ act as exits would
+      try to keep their server lists more aggressively up to date than
+      exits, when it was supposed to be the other way around. Bugfix
+      on 0.2.2.17-alpha.

+ 1 - 1
src/or/dirserv.c

@@ -1213,7 +1213,7 @@ directory_caches_dir_info(or_options_t *options)
     return 0;
     return 0;
   /* We need an up-to-date view of network info if we're going to try to
   /* We need an up-to-date view of network info if we're going to try to
    * block exit attempts from unknown relays. */
    * block exit attempts from unknown relays. */
-  return router_my_exit_policy_is_reject_star() &&
+  return ! router_my_exit_policy_is_reject_star() &&
     should_refuse_unknown_exits(options);
     should_refuse_unknown_exits(options);
 }
 }