aboutsummaryrefslogtreecommitdiff
path: root/src/dht
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2011-10-25 20:51:00 +0000
committerChristian Grothoff <christian@grothoff.org>2011-10-25 20:51:00 +0000
commit4e8e34ae6b609a86cf8c0a6943b8b6ad13ce3a5d (patch)
tree24bf39814cc740560ea0b0d5291408c5e57d65b1 /src/dht
parent5cd4cab9601b06bff31d21b7d39e0247fd39f7b4 (diff)
downloadgnunet-4e8e34ae6b609a86cf8c0a6943b8b6ad13ce3a5d.tar.gz
gnunet-4e8e34ae6b609a86cf8c0a6943b8b6ad13ce3a5d.zip
longer timeout -- trying to see if this helps with 1851 ---- and using named constants
Diffstat (limited to 'src/dht')
-rw-r--r--src/dht/test_dht_2dtorus.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/dht/test_dht_2dtorus.c b/src/dht/test_dht_2dtorus.c
index d7b04f895..220554e15 100644
--- a/src/dht/test_dht_2dtorus.c
+++ b/src/dht/test_dht_2dtorus.c
@@ -40,6 +40,10 @@
40 */ 40 */
41#define TIMEOUT GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, 1500) 41#define TIMEOUT GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, 1500)
42 42
43#define GET_TIMEOUT GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, 120)
44
45#define PUT_FREQUENCY GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, 5)
46
43static int ok; 47static int ok;
44 48
45/** 49/**
@@ -315,8 +319,7 @@ do_test (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc)
315 &dht_get_id_handler, 319 &dht_get_id_handler,
316 NULL); 320 NULL);
317 GNUNET_SCHEDULER_cancel (disconnect_task); 321 GNUNET_SCHEDULER_cancel (disconnect_task);
318 disconnect_task = GNUNET_SCHEDULER_add_delayed( 322 disconnect_task = GNUNET_SCHEDULER_add_delayed(GET_TIMEOUT,
319 GNUNET_TIME_relative_multiply(GNUNET_TIME_UNIT_SECONDS, 30),
320 &disconnect_peers, NULL); 323 &disconnect_peers, NULL);
321} 324}
322 325
@@ -348,9 +351,8 @@ put_id (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc)
348 NULL); 351 NULL);
349 352
350 } 353 }
351 put_task = GNUNET_SCHEDULER_add_delayed( 354 put_task = GNUNET_SCHEDULER_add_delayed(PUT_FREQUENCY,
352 GNUNET_TIME_relative_multiply(GNUNET_TIME_UNIT_SECONDS, 5), 355 &put_id, NULL);
353 &put_id, NULL);
354} 356}
355 357
356 358
@@ -411,9 +413,7 @@ peergroup_ready (void *cls, const char *emsg)
411 GNUNET_TIME_relative_multiply(GNUNET_TIME_UNIT_SECONDS, 2), 413 GNUNET_TIME_relative_multiply(GNUNET_TIME_UNIT_SECONDS, 2),
412 &do_test, NULL); 414 &do_test, NULL);
413 disconnect_task = 415 disconnect_task =
414 GNUNET_SCHEDULER_add_delayed (GNUNET_TIME_relative_multiply( 416 GNUNET_SCHEDULER_add_delayed (GET_TIMEOUT,
415 GNUNET_TIME_UNIT_SECONDS,
416 30),
417 &disconnect_peers, 417 &disconnect_peers,
418 NULL); 418 NULL);
419 419
@@ -552,7 +552,7 @@ run (void *cls, char *const *args, const char *cfgfile,
552 hosts); 552 hosts);
553 GNUNET_assert (pg != NULL); 553 GNUNET_assert (pg != NULL);
554 shutdown_handle = 554 shutdown_handle =
555 GNUNET_SCHEDULER_add_delayed (GNUNET_TIME_relative_get_forever (), 555 GNUNET_SCHEDULER_add_delayed (GNUNET_TIME_UNIT_FOREVER_REL,
556 &shutdown_task, NULL); 556 &shutdown_task, NULL);
557} 557}
558 558