GNUnet  0.11.x
Data Structures | Macros | Functions
testbed_api_cmd_block_until_all_peers_started.c File Reference
#include "platform.h"
#include "gnunet_util_lib.h"
#include "gnunet_testing_ng_lib.h"
Include dependency graph for testbed_api_cmd_block_until_all_peers_started.c:

Go to the source code of this file.

Data Structures

struct  BlockState


#define LOG(kind, ...)   GNUNET_log (kind, __VA_ARGS__)
 Generic logging shortcut. More...


static int block_until_all_peers_started_traits (void *cls, const void **ret, const char *trait, unsigned int index)
static void block_until_all_peers_started_cleanup (void *cls, const struct GNUNET_TESTING_Command *cmd)
static void block_until_all_peers_started_run (void *cls, const struct GNUNET_TESTING_Command *cmd, struct GNUNET_TESTING_Interpreter *is)
static int block_until_all_peers_started_finish (void *cls, GNUNET_SCHEDULER_TaskCallback cont, void *cont_cls)
struct GNUNET_TESTING_Command GNUNET_TESTING_cmd_block_until_all_peers_started (const char *label, unsigned int *all_peers_started)
 Create command. More...

Macro Definition Documentation


#define LOG (   kind,
)    GNUNET_log (kind, __VA_ARGS__)

Function Documentation

◆ block_until_all_peers_started_traits()

static int block_until_all_peers_started_traits ( void *  cls,
const void **  ret,
const char *  trait,
unsigned int  index 

Definition at line 42 of file testbed_api_cmd_block_until_all_peers_started.c.

References GNUNET_OK.

Referenced by GNUNET_TESTING_cmd_block_until_all_peers_started().

46 {
47  return GNUNET_OK;
48 }
Here is the caller graph for this function:

◆ block_until_all_peers_started_cleanup()

static void block_until_all_peers_started_cleanup ( void *  cls,
const struct GNUNET_TESTING_Command cmd 

Definition at line 52 of file testbed_api_cmd_block_until_all_peers_started.c.

References GNUNET_free.

Referenced by GNUNET_TESTING_cmd_block_until_all_peers_started().

54 {
55  struct BlockState *bs = cls;
57  GNUNET_free (bs);
58 }
#define GNUNET_free(ptr)
Wrapper around free.
Here is the caller graph for this function:

◆ block_until_all_peers_started_run()

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

Definition at line 62 of file testbed_api_cmd_block_until_all_peers_started.c.


Referenced by GNUNET_TESTING_cmd_block_until_all_peers_started().

65 {
67  "block_until_all_peers_started_run!\n");
68 }
#define LOG(kind,...)
Generic logging shortcut.
Here is the caller graph for this function:

◆ block_until_all_peers_started_finish()

static int block_until_all_peers_started_finish ( void *  cls,
GNUNET_SCHEDULER_TaskCallback  cont,
void *  cont_cls 

Definition at line 72 of file testbed_api_cmd_block_until_all_peers_started.c.

References BlockState::all_peers_started, GNUNET_ERROR_TYPE_ERROR, GNUNET_YES, LOG, and ret.

Referenced by GNUNET_TESTING_cmd_block_until_all_peers_started().

75 {
76  struct BlockState *bs = cls;
77  unsigned int *ret = bs->all_peers_started;
80  "We got here 10\n");
82  if (GNUNET_YES == *ret)
83  {
85  "We do not need to block anymore!\n");
86  cont (cont_cls);
87  }
88  else
89  {
91  "You shall not pass!\n");
92  }
94  return *ret;
95 }
static int ret
Return value of the commandline.
Definition: gnunet-abd.c:81
#define LOG(kind,...)
Generic logging shortcut.
Here is the caller graph for this function: