aboutsummaryrefslogtreecommitdiff
path: root/src/testbed
diff options
context:
space:
mode:
authorSree Harsha Totakura <totakura@in.tum.de>2012-09-25 12:09:42 +0000
committerSree Harsha Totakura <totakura@in.tum.de>2012-09-25 12:09:42 +0000
commitf45aa9ad24ef852ffd39490b7ce32c213e698b72 (patch)
treecb4716b2be0d65a807ffc55b0a1050913641b23f /src/testbed
parent3655f3e8eded4a06a2d2ccfa75c53d5ad81c26f0 (diff)
downloadgnunet-f45aa9ad24ef852ffd39490b7ce32c213e698b72.tar.gz
gnunet-f45aa9ad24ef852ffd39490b7ce32c213e698b72.zip
added peer2_host field in overlay connect message
Diffstat (limited to 'src/testbed')
-rw-r--r--src/testbed/gnunet-service-testbed.c3
-rw-r--r--src/testbed/testbed.h5
-rw-r--r--src/testbed/testbed_api_peers.c1
3 files changed, 8 insertions, 1 deletions
diff --git a/src/testbed/gnunet-service-testbed.c b/src/testbed/gnunet-service-testbed.c
index c48a1e27f..6edf8d897 100644
--- a/src/testbed/gnunet-service-testbed.c
+++ b/src/testbed/gnunet-service-testbed.c
@@ -1400,7 +1400,8 @@ handle_link_controllers (void *cls, struct GNUNET_SERVER_Client *client,
1400 if ((delegated_host_id >= host_list_size) || 1400 if ((delegated_host_id >= host_list_size) ||
1401 (NULL == host_list[delegated_host_id])) 1401 (NULL == host_list[delegated_host_id]))
1402 { 1402 {
1403 LOG (GNUNET_ERROR_TYPE_WARNING, "Delegated host not registered with us\n"); 1403 LOG (GNUNET_ERROR_TYPE_WARNING,
1404 "Delegated host %u not registered with us\n", delegated_host_id);
1404 GNUNET_SERVER_receive_done (client, GNUNET_SYSERR); 1405 GNUNET_SERVER_receive_done (client, GNUNET_SYSERR);
1405 return; 1406 return;
1406 } 1407 }
diff --git a/src/testbed/testbed.h b/src/testbed/testbed.h
index 24183e8d8..27c8e3b93 100644
--- a/src/testbed/testbed.h
+++ b/src/testbed/testbed.h
@@ -397,6 +397,11 @@ struct GNUNET_TESTBED_OverlayConnectMessage
397 */ 397 */
398 uint32_t peer2 GNUNET_PACKED; 398 uint32_t peer2 GNUNET_PACKED;
399 399
400 /**
401 * The ID of the host which runs peer2
402 */
403 uint32_t peer2_host_id GNUNET_PACKED;
404
400}; 405};
401 406
402 407
diff --git a/src/testbed/testbed_api_peers.c b/src/testbed/testbed_api_peers.c
index 65d4ffbd9..9b35209ca 100644
--- a/src/testbed/testbed_api_peers.c
+++ b/src/testbed/testbed_api_peers.c
@@ -341,6 +341,7 @@ opstart_overlay_connect (void *cls)
341 msg->peer1 = htonl (data->p1->unique_id); 341 msg->peer1 = htonl (data->p1->unique_id);
342 msg->peer2 = htonl (data->p2->unique_id); 342 msg->peer2 = htonl (data->p2->unique_id);
343 msg->operation_id = GNUNET_htonll (opc->id); 343 msg->operation_id = GNUNET_htonll (opc->id);
344 msg->peer2_host_id = htonl (GNUNET_TESTBED_host_get_id_ (data->p2->host));
344 GNUNET_CONTAINER_DLL_insert_tail (opc->c->ocq_head, opc->c->ocq_tail, opc); 345 GNUNET_CONTAINER_DLL_insert_tail (opc->c->ocq_head, opc->c->ocq_tail, opc);
345 GNUNET_TESTBED_queue_message_ (opc->c, &msg->header); 346 GNUNET_TESTBED_queue_message_ (opc->c, &msg->header);
346} 347}