]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
think harder about my logic
authorRoger Dingledine <arma@torproject.org>
Sat, 22 Jul 2006 07:19:11 +0000 (07:19 +0000)
committerRoger Dingledine <arma@torproject.org>
Sat, 22 Jul 2006 07:19:11 +0000 (07:19 +0000)
svn:r6806

src/or/config.c
src/or/main.c

index 9c6577c07ac0c7f87f0e66c510ca1ae9b84f4a45..6f3c4db6b586ae48cead2ff2e9321bc9cebeab09 100644 (file)
@@ -796,7 +796,7 @@ options_act(or_options_t *old_options)
           return -1;
         }
         server_has_changed_ip();
-        if (has_completed_circuit || any_predicted_circuits(time(NULL)))
+        if (has_completed_circuit || !any_predicted_circuits(time(NULL)))
           inform_testing_reachability();
       }
       cpuworkers_rotate();
index cb0e74b37423968e6241c9f8c0725ee34d36d610..b0795f526b5a90b647a74c5abb50fd50f36fdc94 100644 (file)
@@ -569,7 +569,7 @@ directory_info_has_arrived(time_t now, int from_cache)
   }
 
   if (server_mode(options) && !we_are_hibernating() && !from_cache &&
-      (has_completed_circuit || any_predicted_circuits(now)))
+      (has_completed_circuit || !any_predicted_circuits(now)))
     consider_testing_reachability();
 }
 
@@ -833,7 +833,7 @@ run_scheduled_events(time_t now)
     /* also, check religiously for reachability, if it's within the first
      * 20 minutes of our uptime. */
     if (server_mode(options) &&
-        (has_completed_circuit || any_predicted_circuits(now)) &&
+        (has_completed_circuit || !any_predicted_circuits(now)) &&
         stats_n_seconds_working < TIMEOUT_UNTIL_UNREACHABILITY_COMPLAINT &&
         !we_are_hibernating())
       consider_testing_reachability();