/**
 * Destroy a #Slave object
 *
 * @param slave the #Slave object
 */
static void
destroy_slave (struct Slave *slave)
{
  if (NULL != slave->controller_proc)
  {
    GNUNET_TESTBED_controller_destroy_ (slave->controller_proc);
    LOG_DEBUG ("Slave stopped\n");
  }
  GST_slave_list[slave->host_id] = NULL;
  GNUNET_free (slave);
}
Example #2
0
/**
 * Stop the controller process (also will terminate all peers and controllers
 * dependent on this controller).  This function blocks until the testbed has
 * been fully terminated (!). The controller status cb from
 * GNUNET_TESTBED_controller_start() will not be called.
 *
 * @param cproc the controller process handle
 */
void
GNUNET_TESTBED_controller_stop (struct GNUNET_TESTBED_ControllerProc *cproc)
{
  GNUNET_TESTBED_controller_kill_ (cproc);
  GNUNET_TESTBED_controller_destroy_ (cproc);
}