aboutsummaryrefslogtreecommitdiff
path: root/src/transport/test_transport_api_reliability.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2010-06-03 05:31:08 +0000
committerChristian Grothoff <christian@grothoff.org>2010-06-03 05:31:08 +0000
commitd50ff4b0c667247787d42563c6e8898126b71a5a (patch)
tree825740ba974efda0bf6757f38ac65c9a5484cf65 /src/transport/test_transport_api_reliability.c
parent2cf7e89821ddd4bd4e8744636cba60fcaad4ae2a (diff)
downloadgnunet-d50ff4b0c667247787d42563c6e8898126b71a5a.tar.gz
gnunet-d50ff4b0c667247787d42563c6e8898126b71a5a.zip
better timeout, renew on significant progress means shorter timeout on hard(er) errors and longer timeout on slow machines
Diffstat (limited to 'src/transport/test_transport_api_reliability.c')
-rw-r--r--src/transport/test_transport_api_reliability.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/src/transport/test_transport_api_reliability.c b/src/transport/test_transport_api_reliability.c
index fe7b6590e..6be737309 100644
--- a/src/transport/test_transport_api_reliability.c
+++ b/src/transport/test_transport_api_reliability.c
@@ -51,7 +51,7 @@
51/** 51/**
52 * How long until we give up on transmitting the message? 52 * How long until we give up on transmitting the message?
53 */ 53 */
54#define TIMEOUT GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, 300) 54#define TIMEOUT GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, 150)
55 55
56#define MTYPE 12345 56#define MTYPE 12345
57 57
@@ -200,7 +200,14 @@ notify_receive (void *cls,
200#endif 200#endif
201 n++; 201 n++;
202 if (0 == (n % (TOTAL_MSGS/100))) 202 if (0 == (n % (TOTAL_MSGS/100)))
203 fprintf (stderr, "."); 203 {
204 fprintf (stderr, ".");
205 GNUNET_SCHEDULER_cancel (sched, die_task);
206 die_task = GNUNET_SCHEDULER_add_delayed (sched,
207 TIMEOUT,
208 &end_badly,
209 NULL);
210 }
204 if (n == TOTAL_MSGS) 211 if (n == TOTAL_MSGS)
205 end (); 212 end ();
206} 213}