diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/testbed/gnunet-service-testbed.c | 64 | ||||
-rw-r--r-- | src/testbed/test_testbed_api_2peers_1controller.c | 6 |
2 files changed, 37 insertions, 33 deletions
diff --git a/src/testbed/gnunet-service-testbed.c b/src/testbed/gnunet-service-testbed.c index 33070ff84..dd7bed699 100644 --- a/src/testbed/gnunet-service-testbed.c +++ b/src/testbed/gnunet-service-testbed.c | |||
@@ -58,7 +58,7 @@ | |||
58 | /** | 58 | /** |
59 | * Default timeout for operations which may take some time | 59 | * Default timeout for operations which may take some time |
60 | */ | 60 | */ |
61 | #define TIMEOUT GNUNET_TIME_relative_multiply(GNUNET_TIME_UNIT_SECONDS, 5) | 61 | #define TIMEOUT GNUNET_TIME_relative_multiply(GNUNET_TIME_UNIT_SECONDS, 15) |
62 | 62 | ||
63 | /** | 63 | /** |
64 | * The main context information associated with the client which started us | 64 | * The main context information associated with the client which started us |
@@ -2748,7 +2748,7 @@ handle_peer_get_config (void *cls, struct GNUNET_SERVER_Client *client, | |||
2748 | static void | 2748 | static void |
2749 | cleanup_occ (struct OverlayConnectContext *occ) | 2749 | cleanup_occ (struct OverlayConnectContext *occ) |
2750 | { | 2750 | { |
2751 | LOG_DEBUG ("0x%lx: Cleaning up occ\n", occ->op_id); | 2751 | LOG_DEBUG ("0x%llx: Cleaning up occ\n", occ->op_id); |
2752 | GNUNET_free_non_null (occ->emsg); | 2752 | GNUNET_free_non_null (occ->emsg); |
2753 | GNUNET_free_non_null (occ->hello); | 2753 | GNUNET_free_non_null (occ->hello); |
2754 | GNUNET_SERVER_client_drop (occ->client); | 2754 | GNUNET_SERVER_client_drop (occ->client); |
@@ -2825,7 +2825,7 @@ timeout_overlay_connect (void *cls, | |||
2825 | 2825 | ||
2826 | occ->timeout_task = GNUNET_SCHEDULER_NO_TASK; | 2826 | occ->timeout_task = GNUNET_SCHEDULER_NO_TASK; |
2827 | LOG (GNUNET_ERROR_TYPE_WARNING, | 2827 | LOG (GNUNET_ERROR_TYPE_WARNING, |
2828 | "0x%lx: Timeout while connecting peers %u and %u\n", | 2828 | "0x%llx: Timeout while connecting peers %u and %u\n", |
2829 | occ->op_id, occ->peer_id, occ->other_peer_id); | 2829 | occ->op_id, occ->peer_id, occ->other_peer_id); |
2830 | send_operation_fail_msg (occ->client, occ->op_id, occ->emsg); | 2830 | send_operation_fail_msg (occ->client, occ->op_id, occ->emsg); |
2831 | cleanup_occ (occ); | 2831 | cleanup_occ (occ); |
@@ -2870,7 +2870,7 @@ overlay_connect_notify (void *cls, const struct GNUNET_PeerIdentity *new_peer, | |||
2870 | return; | 2870 | return; |
2871 | } | 2871 | } |
2872 | GNUNET_free (new_peer_str); | 2872 | GNUNET_free (new_peer_str); |
2873 | LOG_DEBUG ("0x%lx: Peer %4s connected to peer %4s\n", occ->op_id, | 2873 | LOG_DEBUG ("0x%llx: Peer %4s connected to peer %4s\n", occ->op_id, |
2874 | other_peer_str, GNUNET_i2s (&occ->peer_identity)); | 2874 | other_peer_str, GNUNET_i2s (&occ->peer_identity)); |
2875 | GNUNET_free (other_peer_str); | 2875 | GNUNET_free (other_peer_str); |
2876 | if (GNUNET_SCHEDULER_NO_TASK != occ->send_hello_task) | 2876 | if (GNUNET_SCHEDULER_NO_TASK != occ->send_hello_task) |
@@ -2888,7 +2888,7 @@ overlay_connect_notify (void *cls, const struct GNUNET_PeerIdentity *new_peer, | |||
2888 | } | 2888 | } |
2889 | GNUNET_free_non_null (occ->emsg); | 2889 | GNUNET_free_non_null (occ->emsg); |
2890 | occ->emsg = NULL; | 2890 | occ->emsg = NULL; |
2891 | LOG_DEBUG ("0x%lx: Peers connected - Sending overlay connect success\n", | 2891 | LOG_DEBUG ("0x%llx: Peers connected - Sending overlay connect success\n", |
2892 | occ->op_id); | 2892 | occ->op_id); |
2893 | msg = GNUNET_malloc (sizeof (struct GNUNET_TESTBED_ConnectionEventMessage)); | 2893 | msg = GNUNET_malloc (sizeof (struct GNUNET_TESTBED_ConnectionEventMessage)); |
2894 | msg->header.size = | 2894 | msg->header.size = |
@@ -2930,7 +2930,7 @@ try_connect_cb (void *cls, const int result) | |||
2930 | GNUNET_assert (GNUNET_SCHEDULER_NO_TASK == tcc->task); | 2930 | GNUNET_assert (GNUNET_SCHEDULER_NO_TASK == tcc->task); |
2931 | tcc->task = GNUNET_SCHEDULER_add_delayed (GNUNET_TIME_relative_multiply | 2931 | tcc->task = GNUNET_SCHEDULER_add_delayed (GNUNET_TIME_relative_multiply |
2932 | (GNUNET_TIME_UNIT_MILLISECONDS, | 2932 | (GNUNET_TIME_UNIT_MILLISECONDS, |
2933 | 500 + pow(2, ++tcc->retries)), | 2933 | 500 + pow(2, ++tcc->retries)), |
2934 | &try_connect_task, tcc); | 2934 | &try_connect_task, tcc); |
2935 | } | 2935 | } |
2936 | 2936 | ||
@@ -2952,7 +2952,7 @@ try_connect_task (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
2952 | GNUNET_assert (NULL == tcc->tch); | 2952 | GNUNET_assert (NULL == tcc->tch); |
2953 | GNUNET_assert (NULL != tcc->pid); | 2953 | GNUNET_assert (NULL != tcc->pid); |
2954 | GNUNET_assert (NULL != tcc->th); | 2954 | GNUNET_assert (NULL != tcc->th); |
2955 | LOG_DEBUG ("0x%lx: Trail %u to connect to peer %s\n", tcc->op_id, tcc->retries, | 2955 | LOG_DEBUG ("0x%llx: Trail %u to connect to peer %s\n", tcc->op_id, tcc->retries, |
2956 | GNUNET_i2s(tcc->pid)); | 2956 | GNUNET_i2s(tcc->pid)); |
2957 | tcc->tch = GNUNET_TRANSPORT_try_connect (tcc->th, tcc->pid, &try_connect_cb, tcc); | 2957 | tcc->tch = GNUNET_TRANSPORT_try_connect (tcc->th, tcc->pid, &try_connect_cb, tcc); |
2958 | } | 2958 | } |
@@ -2988,7 +2988,7 @@ occ_hello_sent_cb (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
2988 | { | 2988 | { |
2989 | GNUNET_free_non_null (occ->emsg); | 2989 | GNUNET_free_non_null (occ->emsg); |
2990 | GNUNET_asprintf (&occ->emsg, | 2990 | GNUNET_asprintf (&occ->emsg, |
2991 | "0x%lx: Timeout while offering HELLO to other peer", | 2991 | "0x%llx: Timeout while offering HELLO to other peer", |
2992 | occ->op_id); | 2992 | occ->op_id); |
2993 | occ->send_hello_task = GNUNET_SCHEDULER_add_now (&send_hello, occ); | 2993 | occ->send_hello_task = GNUNET_SCHEDULER_add_now (&send_hello, occ); |
2994 | return; | 2994 | return; |
@@ -2996,7 +2996,7 @@ occ_hello_sent_cb (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
2996 | if (GNUNET_SCHEDULER_REASON_READ_READY != tc->reason) | 2996 | if (GNUNET_SCHEDULER_REASON_READ_READY != tc->reason) |
2997 | return; | 2997 | return; |
2998 | GNUNET_free_non_null (occ->emsg); | 2998 | GNUNET_free_non_null (occ->emsg); |
2999 | GNUNET_asprintf (&occ->emsg, "0x%lx: Timeout while try connect", | 2999 | GNUNET_asprintf (&occ->emsg, "0x%llx: Timeout while try connect", |
3000 | occ->op_id); | 3000 | occ->op_id); |
3001 | occ->tcc.pid = &occ->peer_identity; | 3001 | occ->tcc.pid = &occ->peer_identity; |
3002 | occ->tcc.op_id = occ->op_id; | 3002 | occ->tcc.op_id = occ->op_id; |
@@ -3028,7 +3028,7 @@ send_hello (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
3028 | uint16_t msize; | 3028 | uint16_t msize; |
3029 | uint16_t hello_size; | 3029 | uint16_t hello_size; |
3030 | 3030 | ||
3031 | LOG_DEBUG ("0x%lx: Offering HELLO of %s (size: %u) to %s via Remote " | 3031 | LOG_DEBUG ("0x%llx: Offering HELLO of %s (size: %u) to %s via Remote " |
3032 | "Overlay Request\n", | 3032 | "Overlay Request\n", |
3033 | occ->op_id, | 3033 | occ->op_id, |
3034 | GNUNET_i2s (&occ->peer_identity), | 3034 | GNUNET_i2s (&occ->peer_identity), |
@@ -3048,7 +3048,7 @@ send_hello (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
3048 | } | 3048 | } |
3049 | else | 3049 | else |
3050 | { | 3050 | { |
3051 | LOG_DEBUG ("0x%lx: Offering HELLO of %s to %s\n", | 3051 | LOG_DEBUG ("0x%llx: Offering HELLO of %s to %s\n", |
3052 | occ->op_id, | 3052 | occ->op_id, |
3053 | GNUNET_i2s (&occ->peer_identity), other_peer_str); | 3053 | GNUNET_i2s (&occ->peer_identity), other_peer_str); |
3054 | occ->ohh = GNUNET_TRANSPORT_offer_hello (occ->tcc.th, | 3054 | occ->ohh = GNUNET_TRANSPORT_offer_hello (occ->tcc.th, |
@@ -3110,11 +3110,11 @@ hello_update_cb (void *cls, const struct GNUNET_MessageHeader *hello) | |||
3110 | &empty); | 3110 | &empty); |
3111 | if (GNUNET_YES == empty) | 3111 | if (GNUNET_YES == empty) |
3112 | { | 3112 | { |
3113 | LOG_DEBUG ("0x%lx: HELLO of %s is empty\n", | 3113 | LOG_DEBUG ("0x%llx: HELLO of %s is empty\n", |
3114 | occ->op_id, GNUNET_i2s (&occ->peer_identity)); | 3114 | occ->op_id, GNUNET_i2s (&occ->peer_identity)); |
3115 | return; | 3115 | return; |
3116 | } | 3116 | } |
3117 | LOG_DEBUG ("0x%lx: Received HELLO of %s\n", | 3117 | LOG_DEBUG ("0x%llx: Received HELLO of %s\n", |
3118 | occ->op_id, GNUNET_i2s (&occ->peer_identity)); | 3118 | occ->op_id, GNUNET_i2s (&occ->peer_identity)); |
3119 | occ->hello = GNUNET_malloc (msize); | 3119 | occ->hello = GNUNET_malloc (msize); |
3120 | memcpy (occ->hello, hello, msize); | 3120 | memcpy (occ->hello, hello, msize); |
@@ -3133,14 +3133,14 @@ hello_update_cb (void *cls, const struct GNUNET_MessageHeader *hello) | |||
3133 | NULL); | 3133 | NULL); |
3134 | if (NULL == occ->tcc.th) | 3134 | if (NULL == occ->tcc.th) |
3135 | { | 3135 | { |
3136 | GNUNET_asprintf (&occ->emsg, "0x%lx: Cannot connect to TRANSPORT of %s", | 3136 | GNUNET_asprintf (&occ->emsg, "0x%llx: Cannot connect to TRANSPORT of %s", |
3137 | occ->op_id, GNUNET_i2s (&occ->other_peer_identity)); | 3137 | occ->op_id, GNUNET_i2s (&occ->other_peer_identity)); |
3138 | GNUNET_SCHEDULER_cancel (occ->timeout_task); | 3138 | GNUNET_SCHEDULER_cancel (occ->timeout_task); |
3139 | occ->timeout_task = GNUNET_SCHEDULER_add_now (&timeout_overlay_connect, occ); | 3139 | occ->timeout_task = GNUNET_SCHEDULER_add_now (&timeout_overlay_connect, occ); |
3140 | return; | 3140 | return; |
3141 | } | 3141 | } |
3142 | } | 3142 | } |
3143 | GNUNET_asprintf (&occ->emsg, "0x%lx: Timeout while offering HELLO to %s", | 3143 | GNUNET_asprintf (&occ->emsg, "0x%llx: Timeout while offering HELLO to %s", |
3144 | occ->op_id, GNUNET_i2s (&occ->other_peer_identity)); | 3144 | occ->op_id, GNUNET_i2s (&occ->other_peer_identity)); |
3145 | occ->send_hello_task = GNUNET_SCHEDULER_add_now (&send_hello, occ); | 3145 | occ->send_hello_task = GNUNET_SCHEDULER_add_now (&send_hello, occ); |
3146 | } | 3146 | } |
@@ -3165,7 +3165,7 @@ core_startup_cb (void *cls, struct GNUNET_CORE_Handle *server, | |||
3165 | 3165 | ||
3166 | GNUNET_free_non_null (occ->emsg); | 3166 | GNUNET_free_non_null (occ->emsg); |
3167 | (void) GNUNET_asprintf (&occ->emsg, | 3167 | (void) GNUNET_asprintf (&occ->emsg, |
3168 | "0x%lx: Failed to connect to CORE of peer with" | 3168 | "0x%llx: Failed to connect to CORE of peer with" |
3169 | "id: %u", occ->op_id, occ->peer_id); | 3169 | "id: %u", occ->op_id, occ->peer_id); |
3170 | if ((NULL == server) || (NULL == my_identity)) | 3170 | if ((NULL == server) || (NULL == my_identity)) |
3171 | goto error_return; | 3171 | goto error_return; |
@@ -3181,14 +3181,14 @@ core_startup_cb (void *cls, struct GNUNET_CORE_Handle *server, | |||
3181 | if (NULL == occ->p1th) | 3181 | if (NULL == occ->p1th) |
3182 | { | 3182 | { |
3183 | GNUNET_asprintf (&occ->emsg, | 3183 | GNUNET_asprintf (&occ->emsg, |
3184 | "0x%lx: Cannot connect to TRANSPORT of peer %4s", | 3184 | "0x%llx: Cannot connect to TRANSPORT of peer %4s", |
3185 | occ->op_id, GNUNET_i2s (&occ->peer_identity)); | 3185 | occ->op_id, GNUNET_i2s (&occ->peer_identity)); |
3186 | goto error_return; | 3186 | goto error_return; |
3187 | } | 3187 | } |
3188 | LOG_DEBUG ("0x%lx: Acquiring HELLO of peer %s\n", | 3188 | LOG_DEBUG ("0x%llx: Acquiring HELLO of peer %s\n", |
3189 | occ->op_id, GNUNET_i2s (&occ->peer_identity)); | 3189 | occ->op_id, GNUNET_i2s (&occ->peer_identity)); |
3190 | GNUNET_asprintf (&occ->emsg, | 3190 | GNUNET_asprintf (&occ->emsg, |
3191 | "0x%lx: Timeout while acquiring HELLO of peer %4s", | 3191 | "0x%llx: Timeout while acquiring HELLO of peer %4s", |
3192 | occ->op_id, GNUNET_i2s (&occ->peer_identity)); | 3192 | occ->op_id, GNUNET_i2s (&occ->peer_identity)); |
3193 | occ->ghh = GNUNET_TRANSPORT_get_hello (occ->p1th, &hello_update_cb, occ); | 3193 | occ->ghh = GNUNET_TRANSPORT_get_hello (occ->p1th, &hello_update_cb, occ); |
3194 | return; | 3194 | return; |
@@ -3225,7 +3225,7 @@ overlay_connect_get_config (void *cls, const struct GNUNET_MessageHeader *msg) | |||
3225 | memcpy (&occ->other_peer_identity, &cmsg->peer_identity, | 3225 | memcpy (&occ->other_peer_identity, &cmsg->peer_identity, |
3226 | sizeof (struct GNUNET_PeerIdentity)); | 3226 | sizeof (struct GNUNET_PeerIdentity)); |
3227 | GNUNET_free_non_null (occ->emsg); | 3227 | GNUNET_free_non_null (occ->emsg); |
3228 | GNUNET_asprintf (&occ->emsg, "0x%lx: Timeout while connecting to CORE", | 3228 | GNUNET_asprintf (&occ->emsg, "0x%llx: Timeout while connecting to CORE", |
3229 | occ->op_id); | 3229 | occ->op_id); |
3230 | occ->peer->reference_cnt++; | 3230 | occ->peer->reference_cnt++; |
3231 | occ->ch = | 3231 | occ->ch = |
@@ -3363,7 +3363,7 @@ handle_overlay_connect (void *cls, struct GNUNET_SERVER_Client *client, | |||
3363 | GNUNET_assert (NULL != peer_list[p1]); | 3363 | GNUNET_assert (NULL != peer_list[p1]); |
3364 | peer = peer_list[p1]; | 3364 | peer = peer_list[p1]; |
3365 | operation_id = GNUNET_ntohll (msg->operation_id); | 3365 | operation_id = GNUNET_ntohll (msg->operation_id); |
3366 | LOG_DEBUG ("Received overlay connect for peers %u and %u with op id: 0x%lx\n", | 3366 | LOG_DEBUG ("Received overlay connect for peers %u and %u with op id: 0x%llx\n", |
3367 | p1, p2, operation_id); | 3367 | p1, p2, operation_id); |
3368 | if (GNUNET_YES == peer->is_remote) | 3368 | if (GNUNET_YES == peer->is_remote) |
3369 | { | 3369 | { |
@@ -3371,7 +3371,7 @@ handle_overlay_connect (void *cls, struct GNUNET_SERVER_Client *client, | |||
3371 | struct Route *route_to_peer2_host; | 3371 | struct Route *route_to_peer2_host; |
3372 | struct Route *route_to_peer1_host; | 3372 | struct Route *route_to_peer1_host; |
3373 | 3373 | ||
3374 | LOG_DEBUG ("0x%lx: Forwarding overlay connect\n", operation_id); | 3374 | LOG_DEBUG ("0x%llx: Forwarding overlay connect\n", operation_id); |
3375 | route_to_peer2_host = NULL; | 3375 | route_to_peer2_host = NULL; |
3376 | route_to_peer1_host = NULL; | 3376 | route_to_peer1_host = NULL; |
3377 | route_to_peer2_host = find_dest_route (peer2_host_id); | 3377 | route_to_peer2_host = find_dest_route (peer2_host_id); |
@@ -3476,7 +3476,7 @@ handle_overlay_connect (void *cls, struct GNUNET_SERVER_Client *client, | |||
3476 | || (NULL ==slave_list[peer2_host_id])) | 3476 | || (NULL ==slave_list[peer2_host_id])) |
3477 | { | 3477 | { |
3478 | LOG (GNUNET_ERROR_TYPE_WARNING, | 3478 | LOG (GNUNET_ERROR_TYPE_WARNING, |
3479 | "0x%lx: Configuration of peer2's controller missing for connecting peers" | 3479 | "0x%llx: Configuration of peer2's controller missing for connecting peers" |
3480 | "%u and %u\n", operation_id, p1, p2); | 3480 | "%u and %u\n", operation_id, p1, p2); |
3481 | GNUNET_SERVER_receive_done (client, GNUNET_SYSERR); | 3481 | GNUNET_SERVER_receive_done (client, GNUNET_SYSERR); |
3482 | return; | 3482 | return; |
@@ -3519,7 +3519,7 @@ handle_overlay_connect (void *cls, struct GNUNET_SERVER_Client *client, | |||
3519 | &overlay_connect_get_config, | 3519 | &overlay_connect_get_config, |
3520 | occ); | 3520 | occ); |
3521 | GNUNET_asprintf (&occ->emsg, | 3521 | GNUNET_asprintf (&occ->emsg, |
3522 | "0x%lx: Timeout while getting peer identity of peer " | 3522 | "0x%llx: Timeout while getting peer identity of peer " |
3523 | "with id: %u", occ->op_id, occ->other_peer_id); | 3523 | "with id: %u", occ->op_id, occ->other_peer_id); |
3524 | occ->timeout_task = | 3524 | occ->timeout_task = |
3525 | GNUNET_SCHEDULER_add_delayed (TIMEOUT, | 3525 | GNUNET_SCHEDULER_add_delayed (TIMEOUT, |
@@ -3532,7 +3532,7 @@ handle_overlay_connect (void *cls, struct GNUNET_SERVER_Client *client, | |||
3532 | /* Connect to the core of 1st peer and wait for the 2nd peer to connect */ | 3532 | /* Connect to the core of 1st peer and wait for the 2nd peer to connect */ |
3533 | occ->emsg = GNUNET_strdup ("Timeout while connecting to CORE"); | 3533 | occ->emsg = GNUNET_strdup ("Timeout while connecting to CORE"); |
3534 | GNUNET_asprintf (&occ->emsg, | 3534 | GNUNET_asprintf (&occ->emsg, |
3535 | "0x%lx: Timeout while connecting to CORE of peer with " | 3535 | "0x%llx: Timeout while connecting to CORE of peer with " |
3536 | "id: %u", occ->op_id, occ->peer_id); | 3536 | "id: %u", occ->op_id, occ->peer_id); |
3537 | occ->peer->reference_cnt++; | 3537 | occ->peer->reference_cnt++; |
3538 | occ->ch = | 3538 | occ->ch = |
@@ -3559,7 +3559,7 @@ handle_overlay_connect (void *cls, struct GNUNET_SERVER_Client *client, | |||
3559 | static void | 3559 | static void |
3560 | cleanup_rocc (struct RequestOverlayConnectContext *rocc) | 3560 | cleanup_rocc (struct RequestOverlayConnectContext *rocc) |
3561 | { | 3561 | { |
3562 | LOG_DEBUG ("0x%lx: Cleaning up rocc\n", rocc->op_id); | 3562 | LOG_DEBUG ("0x%llx: Cleaning up rocc\n", rocc->op_id); |
3563 | if (GNUNET_SCHEDULER_NO_TASK != rocc->attempt_connect_task_id) | 3563 | if (GNUNET_SCHEDULER_NO_TASK != rocc->attempt_connect_task_id) |
3564 | GNUNET_SCHEDULER_cancel (rocc->attempt_connect_task_id); | 3564 | GNUNET_SCHEDULER_cancel (rocc->attempt_connect_task_id); |
3565 | if (GNUNET_SCHEDULER_NO_TASK != rocc->timeout_rocc_task_id) | 3565 | if (GNUNET_SCHEDULER_NO_TASK != rocc->timeout_rocc_task_id) |
@@ -3594,7 +3594,7 @@ timeout_rocc_task (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
3594 | 3594 | ||
3595 | GNUNET_assert (rocc->timeout_rocc_task_id != GNUNET_SCHEDULER_NO_TASK); | 3595 | GNUNET_assert (rocc->timeout_rocc_task_id != GNUNET_SCHEDULER_NO_TASK); |
3596 | rocc->timeout_rocc_task_id = GNUNET_SCHEDULER_NO_TASK; | 3596 | rocc->timeout_rocc_task_id = GNUNET_SCHEDULER_NO_TASK; |
3597 | LOG_DEBUG ("0x%lx: rocc timed out\n", rocc->op_id); | 3597 | LOG_DEBUG ("0x%llx: rocc timed out\n", rocc->op_id); |
3598 | cleanup_rocc (rocc); | 3598 | cleanup_rocc (rocc); |
3599 | } | 3599 | } |
3600 | 3600 | ||
@@ -3615,10 +3615,10 @@ transport_connect_notify (void *cls, const struct GNUNET_PeerIdentity *new_peer, | |||
3615 | { | 3615 | { |
3616 | struct RequestOverlayConnectContext *rocc = cls; | 3616 | struct RequestOverlayConnectContext *rocc = cls; |
3617 | 3617 | ||
3618 | LOG_DEBUG ("0x%lx: Request Overlay connect notify\n", rocc->op_id); | 3618 | LOG_DEBUG ("0x%llx: Request Overlay connect notify\n", rocc->op_id); |
3619 | if (0 != memcmp (new_peer, &rocc->a_id, sizeof (struct GNUNET_PeerIdentity))) | 3619 | if (0 != memcmp (new_peer, &rocc->a_id, sizeof (struct GNUNET_PeerIdentity))) |
3620 | return; | 3620 | return; |
3621 | LOG_DEBUG ("0x%lx: Peer %4s connected\n", rocc->op_id, | 3621 | LOG_DEBUG ("0x%llx: Peer %4s connected\n", rocc->op_id, |
3622 | GNUNET_i2s (&rocc->a_id)); | 3622 | GNUNET_i2s (&rocc->a_id)); |
3623 | cleanup_rocc (rocc); | 3623 | cleanup_rocc (rocc); |
3624 | } | 3624 | } |
@@ -3650,7 +3650,7 @@ rocc_hello_sent_cb (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
3650 | 3650 | ||
3651 | rocc->ohh = NULL; | 3651 | rocc->ohh = NULL; |
3652 | GNUNET_assert (GNUNET_SCHEDULER_NO_TASK == rocc->attempt_connect_task_id); | 3652 | GNUNET_assert (GNUNET_SCHEDULER_NO_TASK == rocc->attempt_connect_task_id); |
3653 | LOG_DEBUG ("0x%lx: HELLO of peer %4s sent to local peer with id: %u\n", | 3653 | LOG_DEBUG ("0x%llx: HELLO of peer %4s sent to local peer with id: %u\n", |
3654 | rocc->op_id, GNUNET_i2s (&rocc->a_id), rocc->peer->id); | 3654 | rocc->op_id, GNUNET_i2s (&rocc->a_id), rocc->peer->id); |
3655 | if (GNUNET_SCHEDULER_REASON_TIMEOUT == tc->reason) | 3655 | if (GNUNET_SCHEDULER_REASON_TIMEOUT == tc->reason) |
3656 | { | 3656 | { |
@@ -3680,7 +3680,7 @@ attempt_connect_task (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
3680 | 3680 | ||
3681 | GNUNET_assert (GNUNET_SCHEDULER_NO_TASK != rocc->attempt_connect_task_id); | 3681 | GNUNET_assert (GNUNET_SCHEDULER_NO_TASK != rocc->attempt_connect_task_id); |
3682 | rocc->attempt_connect_task_id = GNUNET_SCHEDULER_NO_TASK; | 3682 | rocc->attempt_connect_task_id = GNUNET_SCHEDULER_NO_TASK; |
3683 | LOG_DEBUG ("0x%lx: Offering HELLO of peer %4s to local peer with id: %u\n", | 3683 | LOG_DEBUG ("0x%llx: Offering HELLO of peer %4s to local peer with id: %u\n", |
3684 | rocc->op_id, GNUNET_i2s (&rocc->a_id), rocc->peer->id); | 3684 | rocc->op_id, GNUNET_i2s (&rocc->a_id), rocc->peer->id); |
3685 | rocc->ohh = GNUNET_TRANSPORT_offer_hello (rocc->tcc.th, rocc->hello, | 3685 | rocc->ohh = GNUNET_TRANSPORT_offer_hello (rocc->tcc.th, rocc->hello, |
3686 | rocc_hello_sent_cb, rocc); | 3686 | rocc_hello_sent_cb, rocc); |
@@ -3755,7 +3755,7 @@ handle_overlay_request_connect (void *cls, struct GNUNET_SERVER_Client *client, | |||
3755 | GNUNET_CONTAINER_DLL_insert_tail (roccq_head, roccq_tail, rocc); | 3755 | GNUNET_CONTAINER_DLL_insert_tail (roccq_head, roccq_tail, rocc); |
3756 | memcpy (&rocc->a_id, &msg->peer_identity, | 3756 | memcpy (&rocc->a_id, &msg->peer_identity, |
3757 | sizeof (struct GNUNET_PeerIdentity)); | 3757 | sizeof (struct GNUNET_PeerIdentity)); |
3758 | LOG_DEBUG ("Received request for overlay connection with op_id: 0x%lx " | 3758 | LOG_DEBUG ("Received request for overlay connection with op_id: 0x%llx " |
3759 | "from local peer %u to peer %4s with hello size: %u\n", | 3759 | "from local peer %u to peer %4s with hello size: %u\n", |
3760 | rocc->op_id, | 3760 | rocc->op_id, |
3761 | peer_id, | 3761 | peer_id, |
diff --git a/src/testbed/test_testbed_api_2peers_1controller.c b/src/testbed/test_testbed_api_2peers_1controller.c index 4de15fc8d..882a467b3 100644 --- a/src/testbed/test_testbed_api_2peers_1controller.c +++ b/src/testbed/test_testbed_api_2peers_1controller.c | |||
@@ -451,7 +451,11 @@ status_cb (void *cls, const struct GNUNET_CONFIGURATION_Handle *cfg, int status) | |||
451 | { | 451 | { |
452 | uint64_t event_mask; | 452 | uint64_t event_mask; |
453 | 453 | ||
454 | FAIL_TEST (GNUNET_OK == status); | 454 | if (GNUNET_OK != status) |
455 | { | ||
456 | cp = NULL; | ||
457 | FAIL_TEST (0); | ||
458 | } | ||
455 | event_mask = 0; | 459 | event_mask = 0; |
456 | event_mask |= (1L << GNUNET_TESTBED_ET_PEER_START); | 460 | event_mask |= (1L << GNUNET_TESTBED_ET_PEER_START); |
457 | event_mask |= (1L << GNUNET_TESTBED_ET_PEER_STOP); | 461 | event_mask |= (1L << GNUNET_TESTBED_ET_PEER_STOP); |