diff options
author | teor <teor2345@gmail.com> | 2017-07-05 01:45:28 +1000 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2017-07-07 13:18:04 -0400 |
commit | 527c0735f11d5a36aa1fb84dc30b624139ba8406 (patch) | |
tree | 694fb93a53d4e791b135b9821669af1bc8b26709 /src/or/directory.c | |
parent | 32f0cbc0f6fc7a53fc88a144e42fea9aca2cd073 (diff) | |
download | tor-527c0735f11d5a36aa1fb84dc30b624139ba8406.tar.gz tor-527c0735f11d5a36aa1fb84dc30b624139ba8406.zip |
Comment that failure schedules always use exponential backoff
Diffstat (limited to 'src/or/directory.c')
-rw-r--r-- | src/or/directory.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/or/directory.c b/src/or/directory.c index ccec810bae..fc210785e0 100644 --- a/src/or/directory.c +++ b/src/or/directory.c @@ -3771,6 +3771,8 @@ find_dl_min_and_max_delay(download_status_t *dls, const or_options_t *options, const smartlist_t *schedule = find_dl_schedule(dls, options); tor_assert(schedule != NULL && smartlist_len(schedule) >= 2); *min = *((int *)(smartlist_get(schedule, 0))); + /* Increment on failure schedules always use exponential backoff, but they + * have a smaller limit when they're deterministic */ if (dls->backoff == DL_SCHED_DETERMINISTIC) *max = *((int *)((smartlist_get(schedule, smartlist_len(schedule) - 1)))); else |