diff options
author | Roger Dingledine <arma@torproject.org> | 2006-09-15 18:07:11 +0000 |
---|---|---|
committer | Roger Dingledine <arma@torproject.org> | 2006-09-15 18:07:11 +0000 |
commit | bfa78b3dea906e2e1458876baf505c5cc128b009 (patch) | |
tree | 23842c62736dd5aadd6b6a3f451c76c7f8e8748a /src/or/router.c | |
parent | a51ec444664835b596379ff0ae1d33a3fd7de6e8 (diff) | |
download | tor-bfa78b3dea906e2e1458876baf505c5cc128b009.tar.gz tor-bfa78b3dea906e2e1458876baf505c5cc128b009.zip |
actually, do the bandwidth test anyway, if you've been up at
least 6 hours at your previous address.
svn:r8403
Diffstat (limited to 'src/or/router.c')
-rw-r--r-- | src/or/router.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/or/router.c b/src/or/router.c index 698882ec05..a5d9b72533 100644 --- a/src/or/router.c +++ b/src/or/router.c @@ -483,14 +483,17 @@ router_dirport_found_reachable(void) } } +#define UPTIME_CUTOFF_FOR_NEW_BANDWIDTH_TEST (6*60*60) + /** Our router has just moved to a new IP. Reset stats. */ void server_has_changed_ip(void) { + if (stats_n_seconds_working > UPTIME_CUTOFF_FOR_NEW_BANDWIDTH_TEST) + reset_bandwidth_test(); stats_n_seconds_working = 0; can_reach_or_port = 0; can_reach_dir_port = 0; -// reset_bandwidth_test(); mark_my_descriptor_dirty(); } |