aboutsummaryrefslogtreecommitdiff
path: root/src/or
diff options
context:
space:
mode:
authorAndrea Shepard <andrea@torproject.org>2013-03-07 05:10:54 -0800
committerAndrea Shepard <andrea@torproject.org>2013-03-07 05:10:54 -0800
commit302d1dae6c468fd2bd5551de654e36b8464a7eab (patch)
treea540e23a8d85d0fbce91fa7d7a3837a8a17bf2c6 /src/or
parentc7947619df826f6c4568c857178d54b8dee17749 (diff)
downloadtor-302d1dae6c468fd2bd5551de654e36b8464a7eab.tar
tor-302d1dae6c468fd2bd5551de654e36b8464a7eab.tar.gz
Make sure expiry check in dirserv_expire_measured_bw_cache() works if time_t is unsigned
Diffstat (limited to 'src/or')
-rw-r--r--src/or/dirserv.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/or/dirserv.c b/src/or/dirserv.c
index 1846dc1ba..3dfa1e74d 100644
--- a/src/or/dirserv.c
+++ b/src/or/dirserv.c
@@ -2125,7 +2125,7 @@ dirserv_expire_measured_bw_cache(time_t now)
e = (mbw_cache_entry_t *)e_v;
if (e) {
/* Check for expiration and remove if so */
- if (now - e->as_of > MAX_MEASUREMENT_AGE) {
+ if (now > e->as_of + MAX_MEASUREMENT_AGE) {
tor_free(e);
rmv = 1;
}