diff options
author | Sree Harsha Totakura <totakura@in.tum.de> | 2012-10-14 12:21:48 +0000 |
---|---|---|
committer | Sree Harsha Totakura <totakura@in.tum.de> | 2012-10-14 12:21:48 +0000 |
commit | 75357bec5d503045dcf5d5cfd5805300e0605d9d (patch) | |
tree | 95508483a8285f39068282002ca85cc114446818 /src/testbed/testbed_api_peers.c | |
parent | 27fcf1fd9a5800ff97eaf8d9863ba48614b378d0 (diff) | |
download | gnunet-75357bec5d503045dcf5d5cfd5805300e0605d9d.tar.gz gnunet-75357bec5d503045dcf5d5cfd5805300e0605d9d.zip |
operation closure in peer start
Diffstat (limited to 'src/testbed/testbed_api_peers.c')
-rw-r--r-- | src/testbed/testbed_api_peers.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/testbed/testbed_api_peers.c b/src/testbed/testbed_api_peers.c index f9d0929ef..c85687e58 100644 --- a/src/testbed/testbed_api_peers.c +++ b/src/testbed/testbed_api_peers.c | |||
@@ -495,13 +495,16 @@ GNUNET_TESTBED_peer_create (struct GNUNET_TESTBED_Controller *controller, | |||
495 | /** | 495 | /** |
496 | * Start the given peer. | 496 | * Start the given peer. |
497 | * | 497 | * |
498 | * @param op_cls the closure for this operation; will be set in | ||
499 | * event->details.operation_finished.op_cls when this operation fails. | ||
498 | * @param peer peer to start | 500 | * @param peer peer to start |
499 | * @param pcc function to call upon completion | 501 | * @param pcc function to call upon completion |
500 | * @param pcc_cls closure for 'pcc' | 502 | * @param pcc_cls closure for 'pcc' |
501 | * @return handle to the operation | 503 | * @return handle to the operation |
502 | */ | 504 | */ |
503 | struct GNUNET_TESTBED_Operation * | 505 | struct GNUNET_TESTBED_Operation * |
504 | GNUNET_TESTBED_peer_start (struct GNUNET_TESTBED_Peer *peer, | 506 | GNUNET_TESTBED_peer_start (void *op_cls, |
507 | struct GNUNET_TESTBED_Peer *peer, | ||
505 | GNUNET_TESTBED_PeerChurnCallback pcc, | 508 | GNUNET_TESTBED_PeerChurnCallback pcc, |
506 | void *pcc_cls) | 509 | void *pcc_cls) |
507 | { | 510 | { |
@@ -515,6 +518,7 @@ GNUNET_TESTBED_peer_start (struct GNUNET_TESTBED_Peer *peer, | |||
515 | opc = GNUNET_malloc (sizeof (struct OperationContext)); | 518 | opc = GNUNET_malloc (sizeof (struct OperationContext)); |
516 | opc->c = peer->controller; | 519 | opc->c = peer->controller; |
517 | opc->data = data; | 520 | opc->data = data; |
521 | opc->op_cls = op_cls; | ||
518 | opc->id = GNUNET_TESTBED_get_next_op_id (opc->c); | 522 | opc->id = GNUNET_TESTBED_get_next_op_id (opc->c); |
519 | opc->type = OP_PEER_START; | 523 | opc->type = OP_PEER_START; |
520 | opc->op = | 524 | opc->op = |