GNUnet  0.11.x
testbed_api_cmd_tng_connect.c File Reference

Go to the source code of this file.


static void tng_connect_run (void *cls, const struct GNUNET_TESTING_Command *cmd, struct GNUNET_TESTING_Interpreter *is)
struct GNUNET_TESTING_Command GNUNET_TESTBED_cmd_tng_connect (const char *label)

Function Documentation

◆ tng_connect_run()

static void tng_connect_run ( void *  cls,
const struct GNUNET_TESTING_Command cmd,
struct GNUNET_TESTING_Interpreter is 

Definition at line 30 of file testbed_api_cmd_tng_connect.c.

References GNUNET_TRANSPORT_application_init().

Referenced by GNUNET_TESTBED_cmd_tng_connect().

33 {
34  struct TngConnectState *tcs = cls;
36  tcs->ah = GNUNET_TRANSPORT_application_init (tcs->cfg);
37 }
struct GNUNET_TRANSPORT_ApplicationHandle * GNUNET_TRANSPORT_application_init(const struct GNUNET_CONFIGURATION_Handle *cfg)
Initialize the TRANSPORT application client handle.
Here is the call graph for this function:
Here is the caller graph for this function:

◆ GNUNET_TESTBED_cmd_tng_connect()

struct GNUNET_TESTING_Command GNUNET_TESTBED_cmd_tng_connect ( const char *  label)

Definition at line 40 of file testbed_api_cmd_tng_connect.c.

References GNUNET_TESTING_Command::cls, GNUNET_new, GNUNET_TESTING_Command::label, and tng_connect_run().

41 {
42  struct TngConnectState *tcs;
44  ts = GNUNET_new (struct TngConnectState);
46  struct GNUNET_TESTING_Command cmd = {
47  .cls = tcs,
48  .label = label,
49  .run = &tng_connect_run,
50  .cleanup = &tmg_connect_cleanup,
51  .traits = &tng_connect_traits
52  };
54  return cmd;
55 }
const char * label
Label for the command.
A command to be run by the interpreter.
#define GNUNET_new(type)
Allocate a struct or union of the given type.
static void tng_connect_run(void *cls, const struct GNUNET_TESTING_Command *cmd, struct GNUNET_TESTING_Interpreter *is)
void * cls
Closure for all commands with command-specific context information.
Here is the call graph for this function: