From 67fad57cfc09d62dcc2d47166a2ab6b4c1d44347 Mon Sep 17 00:00:00 2001 From: "Nathan S. Evans" Date: Tue, 16 Nov 2010 15:39:39 +0000 Subject: [PATCH] Fix for blacklist testcase; more aggressive reconnect attempts. --- src/testing/test_testing_topology_blacklist.c | 6 ++++-- src/testing/testing.c | 5 +---- src/testing/testing_group.c | 4 ++-- 3 files changed, 7 insertions(+), 8 deletions(-) diff --git a/src/testing/test_testing_topology_blacklist.c b/src/testing/test_testing_topology_blacklist.c index 1123c2f39..aa4a9cac7 100644 --- a/src/testing/test_testing_topology_blacklist.c +++ b/src/testing/test_testing_topology_blacklist.c @@ -190,15 +190,17 @@ topology_callback (void *cls, fprintf (dotOutFile, "\tn%s -- n%s;\n", first_daemon->shortname, second_daemon->shortname); } -#if VERBOSE + else { failed_connections++; +#if VERBOSE GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Failed to connect peer %s to peer %s with error :\n%s\n", first_daemon->shortname, second_daemon->shortname, emsg); - } #endif + } + if (total_connections == expected_connections) { diff --git a/src/testing/testing.c b/src/testing/testing.c index 3d1a74e0e..c5ff0eb7b 100644 --- a/src/testing/testing.c +++ b/src/testing/testing.c @@ -1595,9 +1595,6 @@ GNUNET_TESTING_daemons_connect (struct GNUNET_TESTING_Daemon *d1, #endif ctx->d1core = GNUNET_CORE_connect (d1->cfg, 1, -#if NO_MORE_TIMEOUT_FIXME - timeout, -#endif ctx, NULL, &connect_notify, NULL, NULL, @@ -1657,7 +1654,7 @@ GNUNET_TESTING_daemons_connect (struct GNUNET_TESTING_Daemon *d1, GNUNET_SCHEDULER_add_delayed (GNUNET_TIME_relative_divide (ctx->relative_timeout, ctx->max_connect_attempts), - ¬ify_connect_result, ctx); + ¬ify_connect_result, ctx); ctx->hello_send_task = GNUNET_SCHEDULER_add_now (&send_hello, ctx); } diff --git a/src/testing/testing_group.c b/src/testing/testing_group.c index e74d5b9ef..a0771ae50 100644 --- a/src/testing/testing_group.c +++ b/src/testing/testing_group.c @@ -59,9 +59,9 @@ #define MAX_CONCURRENT_SHUTDOWN 10 -#define CONNECT_TIMEOUT GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, 300) +#define CONNECT_TIMEOUT GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, 200) -#define CONNECT_ATTEMPTS 8 +#define CONNECT_ATTEMPTS 21 /** * Prototype of a function called whenever two peers would be connected -- 2.25.1