-struct ResolutionContext
-{
- struct ResolutionContext *next;
- struct ResolutionContext *prev;
- struct GNUNET_HELLO_Address *addrcp;
- struct GNUNET_TRANSPORT_AddressToStringContext *asc;
- int printed;
-};
-
-
-static void
-operation_timeout (void *cls,
- const struct GNUNET_SCHEDULER_TaskContext *tc)
-{
- struct ResolutionContext *cur;
- struct ResolutionContext *next;
- op_timeout = GNUNET_SCHEDULER_NO_TASK;
- if ((try_connect) || (benchmark_send) ||
- (benchmark_receive))
- {
- FPRINTF (stdout, _("Failed to connect to `%s'\n"), GNUNET_h2s_full (&pid.hashPubKey));
- if (GNUNET_SCHEDULER_NO_TASK != end)
- GNUNET_SCHEDULER_cancel (end);
- end = GNUNET_SCHEDULER_add_now (&shutdown_task, NULL);
- ret = 1;
- return;
- }
- if (iterate_connections)
- {
- next = rc_head;
- while (NULL != (cur = next))
- {
- next = cur->next;
- FPRINTF (stdout, _("Failed to resolve address for peer `%s'\n"),
- GNUNET_i2s (&cur->addrcp->peer));
-
- GNUNET_CONTAINER_DLL_remove (rc_head, rc_tail, cur);
- GNUNET_TRANSPORT_address_to_string_cancel (cur->asc);
- GNUNET_free (cur->addrcp);
- GNUNET_free (cur);
-
- }
- FPRINTF (stdout, "%s", _("Failed to list connections, timeout occured\n"));
- if (GNUNET_SCHEDULER_NO_TASK != end)
- GNUNET_SCHEDULER_cancel (end);
- end = GNUNET_SCHEDULER_add_now (&shutdown_task, NULL);
- ret = 1;
- return;
- }
-
-}
-
-
-
-/**
- * Display the result of the test.
- *
- * @param tc test context
- * @param result GNUNET_YES on success
- */
-static void
-display_test_result (struct TestContext *tc, int result)
-{
- if (GNUNET_YES != result)
- {
- FPRINTF (stderr, "Configuration for plugin `%s' did not work!\n", tc->name);
- }
- else
- {
- FPRINTF (stderr, "Configuration for plugin `%s' is working!\n", tc->name);
- }
- if (GNUNET_SCHEDULER_NO_TASK != tc->tsk)