aboutsummaryrefslogtreecommitdiff
path: root/src/transport/transport_api_cmd_connecting_peers_v3.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/transport/transport_api_cmd_connecting_peers_v3.c')
-rw-r--r--src/transport/transport_api_cmd_connecting_peers_v3.c48
1 files changed, 16 insertions, 32 deletions
diff --git a/src/transport/transport_api_cmd_connecting_peers_v3.c b/src/transport/transport_api_cmd_connecting_peers_v3.c
index a73d81064..ae32a087a 100644
--- a/src/transport/transport_api_cmd_connecting_peers_v3.c
+++ b/src/transport/transport_api_cmd_connecting_peers_v3.c
@@ -59,6 +59,11 @@
59struct ConnectPeersState 59struct ConnectPeersState
60{ 60{
61 /** 61 /**
62 * Context for our asynchronous completion.
63 */
64 struct GNUNET_TESTING_AsyncContext ac;
65
66 /**
62 * The testing system of this node. 67 * The testing system of this node.
63 */ 68 */
64 struct GNUNET_TESTING_System *tl_system; 69 struct GNUNET_TESTING_System *tl_system;
@@ -448,20 +453,6 @@ connect_peers_finish (void *cls,
448 453
449 454
450/** 455/**
451 * Trait function of this cmd does nothing.
452 *
453 */
454static int
455connect_peers_traits (void *cls,
456 const void **ret,
457 const char *trait,
458 unsigned int index)
459{
460 return GNUNET_OK;
461}
462
463
464/**
465 * The cleanup function of this cmd frees resources the cmd allocated. 456 * The cleanup function of this cmd frees resources the cmd allocated.
466 * 457 *
467 */ 458 */
@@ -475,13 +466,6 @@ connect_peers_cleanup (void *cls)
475} 466}
476 467
477 468
478/**
479 * Create command.
480 *
481 * @param label name for command.
482 * @param start_peer_label Label of the cmd to start a peer.
483 * @return command.
484 */
485struct GNUNET_TESTING_Command 469struct GNUNET_TESTING_Command
486GNUNET_TRANSPORT_cmd_connect_peers_v3 (const char *label, 470GNUNET_TRANSPORT_cmd_connect_peers_v3 (const char *label,
487 const char *start_peer_label, 471 const char *start_peer_label,
@@ -498,15 +482,15 @@ GNUNET_TRANSPORT_cmd_connect_peers_v3 (const char *label,
498 cps->create_label = create_label; 482 cps->create_label = create_label;
499 cps->topology = topology; 483 cps->topology = topology;
500 484
501 485 {
502 struct GNUNET_TESTING_Command cmd = { 486 struct GNUNET_TESTING_Command cmd = {
503 .cls = cps, 487 .cls = cps,
504 .label = label, 488 .label = label,
505 .run = &connect_peers_run, 489 .run = &connect_peers_run,
506 .finish = &connect_peers_finish, 490 .ac = &cps->ac,
507 .cleanup = &connect_peers_cleanup, 491 .cleanup = &connect_peers_cleanup
508 .traits = &connect_peers_traits 492 };
509 }; 493
510 494 return cmd;
511 return cmd; 495 }
512} 496}