aboutsummaryrefslogtreecommitdiff
path: root/src/testbed/test_testbed_api_3peers_3controllers.c
diff options
context:
space:
mode:
authorSree Harsha Totakura <totakura@in.tum.de>2013-03-18 13:11:36 +0000
committerSree Harsha Totakura <totakura@in.tum.de>2013-03-18 13:11:36 +0000
commitd0d39def77f1f81dd83823e0fe2cfe84a5393a74 (patch)
tree7c566f79daa839bc74569a415c1b0d2537263280 /src/testbed/test_testbed_api_3peers_3controllers.c
parent153c0ba219f50e851aaef92d0cef28f80a33763e (diff)
downloadgnunet-d0d39def77f1f81dd83823e0fe2cfe84a5393a74.tar.gz
gnunet-d0d39def77f1f81dd83823e0fe2cfe84a5393a74.zip
expose Operation and associated closure in every event
Diffstat (limited to 'src/testbed/test_testbed_api_3peers_3controllers.c')
-rw-r--r--src/testbed/test_testbed_api_3peers_3controllers.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/testbed/test_testbed_api_3peers_3controllers.c b/src/testbed/test_testbed_api_3peers_3controllers.c
index 526386f01..12b14258f 100644
--- a/src/testbed/test_testbed_api_3peers_3controllers.c
+++ b/src/testbed/test_testbed_api_3peers_3controllers.c
@@ -456,7 +456,7 @@ controller_cb (void *cls, const struct GNUNET_TESTBED_EventInformation *event)
456 switch (event->type) 456 switch (event->type)
457 { 457 {
458 case GNUNET_TESTBED_ET_OPERATION_FINISHED: 458 case GNUNET_TESTBED_ET_OPERATION_FINISHED:
459 if ((NULL != event->details.operation_finished.op_cls) || 459 if ((NULL != event->op_cls) ||
460 (NULL != event->details.operation_finished.emsg)) 460 (NULL != event->details.operation_finished.emsg))
461 { 461 {
462 GNUNET_break (0); 462 GNUNET_break (0);
@@ -472,19 +472,19 @@ controller_cb (void *cls, const struct GNUNET_TESTBED_EventInformation *event)
472 abort_test (); 472 abort_test ();
473 return; 473 return;
474 } 474 }
475 if (event->details.operation_finished.operation == peer1.operation) 475 if (event->op == peer1.operation)
476 { 476 {
477 GNUNET_TESTBED_operation_done (peer1.operation); 477 GNUNET_TESTBED_operation_done (peer1.operation);
478 peer1.operation = NULL; 478 peer1.operation = NULL;
479 peer1.peer = NULL; 479 peer1.peer = NULL;
480 } 480 }
481 else if (event->details.operation_finished.operation == peer2.operation) 481 else if (event->op == peer2.operation)
482 { 482 {
483 GNUNET_TESTBED_operation_done (peer2.operation); 483 GNUNET_TESTBED_operation_done (peer2.operation);
484 peer2.operation = NULL; 484 peer2.operation = NULL;
485 peer2.peer = NULL; 485 peer2.peer = NULL;
486 } 486 }
487 else if (event->details.operation_finished.operation == peer3.operation) 487 else if (event->op == peer3.operation)
488 { 488 {
489 GNUNET_TESTBED_operation_done (peer3.operation); 489 GNUNET_TESTBED_operation_done (peer3.operation);
490 peer3.operation = NULL; 490 peer3.operation = NULL;
@@ -706,9 +706,9 @@ controller_cb (void *cls, const struct GNUNET_TESTBED_EventInformation *event)
706 common_operation = NULL; 706 common_operation = NULL;
707 result = PEERS_CONNECTED_2; 707 result = PEERS_CONNECTED_2;
708 LOG (GNUNET_ERROR_TYPE_DEBUG, "Peers connected again\n"); 708 LOG (GNUNET_ERROR_TYPE_DEBUG, "Peers connected again\n");
709 peer1.operation = GNUNET_TESTBED_peer_stop (peer1.peer, NULL, NULL); 709 peer1.operation = GNUNET_TESTBED_peer_stop (NULL, peer1.peer, NULL, NULL);
710 peer2.operation = GNUNET_TESTBED_peer_stop (peer2.peer, NULL, NULL); 710 peer2.operation = GNUNET_TESTBED_peer_stop (NULL, peer2.peer, NULL, NULL);
711 peer3.operation = GNUNET_TESTBED_peer_stop (peer3.peer, NULL, NULL); 711 peer3.operation = GNUNET_TESTBED_peer_stop (NULL, peer3.peer, NULL, NULL);
712 break; 712 break;
713 default: 713 default:
714 GNUNET_break (0); 714 GNUNET_break (0);