summaryrefslogtreecommitdiff
path: root/toxcore/onion_client.h
diff options
context:
space:
mode:
Diffstat (limited to 'toxcore/onion_client.h')
-rw-r--r--toxcore/onion_client.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/toxcore/onion_client.h b/toxcore/onion_client.h
index daf08a74..a99383c5 100644
--- a/toxcore/onion_client.h
+++ b/toxcore/onion_client.h
@@ -41,8 +41,9 @@
41/* The timeout the first time the path is added and 41/* The timeout the first time the path is added and
42 then for all the next consecutive times */ 42 then for all the next consecutive times */
43#define ONION_PATH_FIRST_TIMEOUT 5 43#define ONION_PATH_FIRST_TIMEOUT 5
44#define ONION_PATH_TIMEOUT 30 44#define ONION_PATH_TIMEOUT 10
45#define ONION_PATH_MAX_LIFETIME 600 45#define ONION_PATH_MAX_LIFETIME 1200
46#define ONION_PATH_MAX_NO_RESPONSE_USES 4
46 47
47#define MAX_STORED_PINGED_NODES 9 48#define MAX_STORED_PINGED_NODES 9
48#define MIN_NODE_PING_TIME 10 49#define MIN_NODE_PING_TIME 10
@@ -71,7 +72,10 @@ typedef struct {
71typedef struct { 72typedef struct {
72 Onion_Path paths[NUMBER_ONION_PATHS]; 73 Onion_Path paths[NUMBER_ONION_PATHS];
73 uint64_t last_path_success[NUMBER_ONION_PATHS]; 74 uint64_t last_path_success[NUMBER_ONION_PATHS];
75 uint64_t last_path_used[NUMBER_ONION_PATHS];
74 uint64_t path_creation_time[NUMBER_ONION_PATHS]; 76 uint64_t path_creation_time[NUMBER_ONION_PATHS];
77 /* number of times used without success. */
78 unsigned int last_path_used_times[NUMBER_ONION_PATHS];
75} Onion_Client_Paths; 79} Onion_Client_Paths;
76 80
77typedef struct { 81typedef struct {