diff options
author | George Kadianakis <desnacked@riseup.net> | 2019-04-18 13:23:32 +0300 |
---|---|---|
committer | George Kadianakis <desnacked@riseup.net> | 2019-04-18 13:23:32 +0300 |
commit | 78223ab0fc279abe0c575f191f5d0f42ef1bda59 (patch) | |
tree | edd638b89ae31dd40d48cba0a1cafa92c06f5c69 /src/feature/relay/onion_queue.c | |
parent | 2db9bb02c79e023128e7b6fc89f4601b88e8ef4b (diff) | |
parent | 73323460023807259d3cd1dd52d33749ffe53886 (diff) | |
download | tor-78223ab0fc279abe0c575f191f5d0f42ef1bda59.tar.gz tor-78223ab0fc279abe0c575f191f5d0f42ef1bda59.zip |
Merge branch 'tor-github/pr/938'
Diffstat (limited to 'src/feature/relay/onion_queue.c')
-rw-r--r-- | src/feature/relay/onion_queue.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/feature/relay/onion_queue.c b/src/feature/relay/onion_queue.c index 696905cf5e..c37745cf33 100644 --- a/src/feature/relay/onion_queue.c +++ b/src/feature/relay/onion_queue.c @@ -212,10 +212,12 @@ num_ntors_per_tap(void) #define MIN_NUM_NTORS_PER_TAP 1 #define MAX_NUM_NTORS_PER_TAP 100000 - return networkstatus_get_param(NULL, "NumNTorsPerTAP", - DEFAULT_NUM_NTORS_PER_TAP, - MIN_NUM_NTORS_PER_TAP, - MAX_NUM_NTORS_PER_TAP); + int result = networkstatus_get_param(NULL, "NumNTorsPerTAP", + DEFAULT_NUM_NTORS_PER_TAP, + MIN_NUM_NTORS_PER_TAP, + MAX_NUM_NTORS_PER_TAP); + tor_assert(result > 0); + return result; } /** Choose which onion queue we'll pull from next. If one is empty choose |