GNUnet  0.10.x
Functions
gnunet-service-transport_manipulation.h File Reference
#include "platform.h"
#include "gnunet-service-transport_hello.h"
#include "gnunet-service-transport_neighbours.h"
#include "gnunet-service-transport_plugins.h"
#include "gnunet-service-transport_validation.h"
#include "gnunet-service-transport.h"
#include "transport.h"
Include dependency graph for gnunet-service-transport_manipulation.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

void GST_manipulation_set_metric (const struct TrafficMetricMessage *tm)
 Set traffic metric to manipulate. More...
 
void GST_manipulation_send (const struct GNUNET_PeerIdentity *target, const void *msg, size_t msg_size, struct GNUNET_TIME_Relative timeout, GST_NeighbourSendContinuation cont, void *cont_cls)
 Adapter function between transport's send function and transport plugins. More...
 
struct GNUNET_TIME_Relative GST_manipulation_recv (void *cls, const struct GNUNET_HELLO_Address *address, struct GNUNET_ATS_Session *session, const struct GNUNET_MessageHeader *message)
 Adapter function between transport plugins and transport receive function manipulation delays for next send. More...
 
void GST_manipulation_manipulate_metrics (const struct GNUNET_HELLO_Address *address, struct GNUNET_ATS_Session *session, struct GNUNET_ATS_Properties *prop)
 Function that will be called to manipulate ATS information according to current manipulation settings. More...
 
void GST_manipulation_peer_disconnect (const struct GNUNET_PeerIdentity *peer)
 Notify manipulation about disconnect so it can discard queued messages. More...
 
void GST_manipulation_init (void)
 Initialize traffic manipulation. More...
 
void GST_manipulation_stop (void)
 Stop traffic manipulation. More...
 

Function Documentation

◆ GST_manipulation_set_metric()

void GST_manipulation_set_metric ( const struct TrafficMetricMessage tm)

Set traffic metric to manipulate.

Parameters
messagecontaining information

Definition at line 174 of file gnunet-service-transport_manipulation.c.

References TrafficMetricMessage::delay_in, TM_Peer::delay_in, TrafficMetricMessage::delay_out, TM_Peer::delay_out, GNUNET_ATS_properties_ntoh(), GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST, GNUNET_CONTAINER_multipeermap_get(), GNUNET_CONTAINER_multipeermap_put(), GNUNET_ERROR_TYPE_DEBUG, GNUNET_i2s(), GNUNET_log, GNUNET_new, GNUNET_TIME_relative_ntoh(), TrafficMetricMessage::peer, TM_Peer::peer, TrafficMetricMessage::properties, and TM_Peer::properties.

Referenced by handle_client_set_metric().

175 {
176  static struct GNUNET_PeerIdentity zero;
177  struct TM_Peer *tmp;
178 
179  if (0 == memcmp (&tm->peer,
180  &zero,
181  sizeof(struct GNUNET_PeerIdentity)))
182  {
184  "Received traffic metrics for all peers\n");
187  return;
188  }
190  "Received traffic metrics for peer `%s'\n",
191  GNUNET_i2s (&tm->peer));
192  if (NULL ==
194  &tm->peer)))
195  {
196  tmp = GNUNET_new (struct TM_Peer);
197  tmp->peer = tm->peer;
199  &tm->peer,
200  tmp,
202  }
204  &tm->properties);
207 }
static const struct GNUNET_CRYPTO_EcdsaPrivateKey zero
Public key of all zeros.
struct GNUNET_PeerIdentity peer
The identity of the peer to look up.
Definition: transport.h:523
static struct GNUNET_TIME_Relative delay_in
Inbound delay to apply to all peers.
struct GNUNET_TIME_Relative delay_in
How long to delay incoming messages for this peer.
struct GNUNET_TIME_Relative delay_out
How long to delay outgoing messages for this peer.
struct GNUNET_TIME_RelativeNBO delay_in
Fake delay to add on inbound traffic.
Definition: transport.h:533
#define GNUNET_new(type)
Allocate a struct or union of the given type.
struct GNUNET_TIME_RelativeNBO delay_out
Fake delay to add on outbound traffic.
Definition: transport.h:538
static struct GNUNET_CONTAINER_MultiPeerMap * peers
Hashmap contain all peers currently manipulated.
, ' bother checking if a value already exists (faster than GNUNET_CONTAINER_MULTIHASHMAPOPTION_...
Struct containing information about manipulations to a specific peer.
struct GNUNET_ATS_Properties properties
Manipulated properties to use for this peer.
struct GNUNET_TIME_Relative GNUNET_TIME_relative_ntoh(struct GNUNET_TIME_RelativeNBO a)
Convert relative time from network byte order.
Definition: time.c:638
struct GNUNET_ATS_PropertiesNBO properties
Fake properties to generate.
Definition: transport.h:528
static struct GNUNET_TIME_Relative delay_out
Outbound delay to apply to all peers.
int GNUNET_CONTAINER_multipeermap_put(struct GNUNET_CONTAINER_MultiPeerMap *map, const struct GNUNET_PeerIdentity *key, void *value, enum GNUNET_CONTAINER_MultiHashMapOption opt)
Store a key-value pair in the map.
The identity of the host (wraps the signing key of the peer).
void GNUNET_ATS_properties_ntoh(struct GNUNET_ATS_Properties *hbo, const struct GNUNET_ATS_PropertiesNBO *nbo)
Convert ATS properties from network to host byte order.
void * GNUNET_CONTAINER_multipeermap_get(const struct GNUNET_CONTAINER_MultiPeerMap *map, const struct GNUNET_PeerIdentity *key)
Given a key find a value in the map matching the key.
#define GNUNET_log(kind,...)
struct GNUNET_PeerIdentity peer
Peer ID.
const char * GNUNET_i2s(const struct GNUNET_PeerIdentity *pid)
Convert a peer identity to a string (for printing debug messages).
Here is the call graph for this function:
Here is the caller graph for this function:

◆ GST_manipulation_send()

void GST_manipulation_send ( const struct GNUNET_PeerIdentity target,
const void *  msg,
size_t  msg_size,
struct GNUNET_TIME_Relative  timeout,
GST_NeighbourSendContinuation  cont,
void *  cont_cls 
)

Adapter function between transport's send function and transport plugins.

Parameters
targetthe peer the message to send to
msgthe message received
msg_sizemessage size
timeouttimeout
contthe continuation to call after sending
cont_clscls for continuation

Delays message transmission if an artificial delay is configured.

Parameters
targetthe peer the message to send to
msgthe message received
msg_sizemessage size
timeouttimeout
contthe continuation to call after sending
cont_clscls for cont

Definition at line 278 of file gnunet-service-transport_manipulation.c.

References DelayQueueEntry::cont, DelayQueueEntry::cont_cls, TM_Peer::delay_out, GNUNET_CONTAINER_DLL_insert_tail, GNUNET_CONTAINER_multipeermap_get(), GNUNET_ERROR_TYPE_DEBUG, GNUNET_i2s(), GNUNET_log, GNUNET_malloc, GNUNET_memcpy, GNUNET_SCHEDULER_add_delayed(), GNUNET_STRINGS_relative_time_to_string(), GNUNET_TIME_relative_to_absolute(), GNUNET_YES, GST_neighbours_send(), DelayQueueEntry::id, DelayQueueEntry::msg, DelayQueueEntry::msg_size, GNUNET_TIME_Relative::rel_value_us, TM_Peer::send_delay_task, send_delayed(), TM_Peer::send_head, TM_Peer::send_tail, DelayQueueEntry::sent_at, timeout, DelayQueueEntry::timeout, and DelayQueueEntry::tmp.

Referenced by handle_client_send().

284 {
285  struct TM_Peer *tmp;
286  struct DelayQueueEntry *dqe;
288 
289  if (NULL != (tmp =
291  target)))
292  delay = tmp->delay_out;
293  else
294  delay = delay_out;
295  if (0 == delay.rel_value_us)
296  {
297  /* Normal sending */
298  GST_neighbours_send (target,
299  msg,
300  msg_size,
301  timeout,
302  cont, cont_cls);
303  return;
304  }
305  dqe = GNUNET_malloc (sizeof (struct DelayQueueEntry) + msg_size);
306  dqe->id = *target;
307  dqe->tmp = tmp;
309  dqe->cont = cont;
310  dqe->cont_cls = cont_cls;
311  dqe->msg = &dqe[1];
312  dqe->msg_size = msg_size;
313  dqe->timeout = timeout;
314  GNUNET_memcpy (dqe->msg,
315  msg,
316  msg_size);
317  if (NULL == tmp)
318  {
321  dqe);
322  if (NULL == generic_send_delay_task)
324  &send_delayed,
325  dqe);
326  }
327  else
328  {
330  tmp->send_tail,
331  dqe);
332  if (NULL == tmp->send_delay_task)
334  &send_delayed,
335  dqe);
336  }
338  "Delaying %u byte message to peer `%s' with peer specific delay for %s\n",
339  (unsigned int) msg_size,
340  GNUNET_i2s (target),
342  GNUNET_YES));
343 }
Entry in the delay queue for an outbound delayed message.
struct DelayQueueEntry * send_head
Send queue DLL head.
struct DelayQueueEntry * send_tail
Send queue DLL tail.
struct GNUNET_MessageHeader * msg
Definition: 005.c:2
void * cont_cls
Transports send continuation cls.
uint64_t rel_value_us
The actual value.
struct GNUNET_TIME_Relative delay_out
How long to delay outgoing messages for this peer.
struct TM_Peer * tmp
Peer this entry is belonging to if (NULL == tmp): enqueued in generic DLL and scheduled by generic_se...
struct GNUNET_TIME_Absolute GNUNET_TIME_relative_to_absolute(struct GNUNET_TIME_Relative rel)
Convert relative time to an absolute time in the future.
Definition: time.c:245
GST_NeighbourSendContinuation cont
Transports send continuation.
struct GNUNET_SCHEDULER_Task * GNUNET_SCHEDULER_add_delayed(struct GNUNET_TIME_Relative delay, GNUNET_SCHEDULER_TaskCallback task, void *task_cls)
Schedule a new task to be run with a specified delay.
Definition: scheduler.c:1246
struct GNUNET_SCHEDULER_Task * send_delay_task
Task to schedule delayed sendding.
static struct GNUNET_TIME_Relative timeout
User defined timestamp for completing operations.
Definition: gnunet-arm.c:114
#define GNUNET_memcpy(dst, src, n)
static struct GNUNET_CONTAINER_MultiPeerMap * peers
Hashmap contain all peers currently manipulated.
Struct containing information about manipulations to a specific peer.
static void send_delayed(void *cls)
We have delayed transmission, now it is time to send the message.
const char * GNUNET_STRINGS_relative_time_to_string(struct GNUNET_TIME_Relative delta, int do_round)
Give relative time in human-readable fancy format.
Definition: strings.c:727
#define GNUNET_CONTAINER_DLL_insert_tail(head, tail, element)
Insert an element at the tail of a DLL.
static struct GNUNET_TIME_Relative delay
When should dkg communication start?
static struct GNUNET_TIME_Relative delay_out
Outbound delay to apply to all peers.
static struct DelayQueueEntry * generic_dqe_head
DLL head for delayed messages based on general delay.
static struct GNUNET_SCHEDULER_Task * generic_send_delay_task
Task to schedule delayed sending based on general delay.
void * GNUNET_CONTAINER_multipeermap_get(const struct GNUNET_CONTAINER_MultiPeerMap *map, const struct GNUNET_PeerIdentity *key)
Given a key find a value in the map matching the key.
#define GNUNET_log(kind,...)
void GST_neighbours_send(const struct GNUNET_PeerIdentity *target, const void *msg, size_t msg_size, struct GNUNET_TIME_Relative timeout, GST_NeighbourSendContinuation cont, void *cont_cls)
Transmit a message to the given target using the active connection.
struct GNUNET_TIME_Relative timeout
Message timeout.
#define GNUNET_YES
Definition: gnunet_common.h:80
struct GNUNET_TIME_Absolute sent_at
Absolute time when to send.
static struct DelayQueueEntry * generic_dqe_tail
DLL tail for delayed messages based on general delay.
struct GNUNET_PeerIdentity id
Peer ID.
const char * GNUNET_i2s(const struct GNUNET_PeerIdentity *pid)
Convert a peer identity to a string (for printing debug messages).
#define GNUNET_malloc(size)
Wrapper around malloc.
Time for relative time used by GNUnet, in microseconds.
Here is the call graph for this function:
Here is the caller graph for this function:

◆ GST_manipulation_recv()

struct GNUNET_TIME_Relative GST_manipulation_recv ( void *  cls,
const struct GNUNET_HELLO_Address address,
struct GNUNET_ATS_Session session,
const struct GNUNET_MessageHeader message 
)

Adapter function between transport plugins and transport receive function manipulation delays for next send.

Parameters
clsthe closure for transport
addressthe address and the peer the message was received from
messagethe message received
sessionthe session the message was received on
Returns
manipulated delay for next receive

Definition at line 380 of file gnunet-service-transport_manipulation.c.

References TM_Peer::delay_in, GNUNET_CONTAINER_multipeermap_get(), GNUNET_ERROR_TYPE_DEBUG, GNUNET_i2s(), GNUNET_log, GNUNET_STRINGS_relative_time_to_string(), GNUNET_TIME_relative_max(), GNUNET_YES, GST_receive_callback(), and GNUNET_HELLO_Address::peer.

Referenced by run().

384 {
385  struct TM_Peer *tmp;
386  struct GNUNET_TIME_Relative quota_delay;
387  struct GNUNET_TIME_Relative m_delay;
388 
389  if (NULL !=
391  &address->peer)))
392  m_delay = tmp->delay_in;
393  else
394  m_delay = delay_in;
395 
396  quota_delay = GST_receive_callback (cls,
397  address,
398  session,
399  message);
400  m_delay = GNUNET_TIME_relative_max (m_delay,
401  quota_delay);
403  "Delaying next receive for peer `%s' for %s\n",
404  GNUNET_i2s (&address->peer),
406  GNUNET_YES));
407  return m_delay;
408 }
static struct GNUNET_TIME_Relative delay_in
Inbound delay to apply to all peers.
struct GNUNET_TIME_Relative delay_in
How long to delay incoming messages for this peer.
struct GNUNET_TIME_Relative GNUNET_TIME_relative_max(struct GNUNET_TIME_Relative t1, struct GNUNET_TIME_Relative t2)
Return the maximum of two relative time values.
Definition: time.c:286
static struct GNUNET_CONTAINER_MultiPeerMap * peers
Hashmap contain all peers currently manipulated.
Struct containing information about manipulations to a specific peer.
const char * GNUNET_STRINGS_relative_time_to_string(struct GNUNET_TIME_Relative delta, int do_round)
Give relative time in human-readable fancy format.
Definition: strings.c:727
struct GNUNET_TIME_Relative GST_receive_callback(void *cls, const struct GNUNET_HELLO_Address *address, struct GNUNET_ATS_Session *session, const struct GNUNET_MessageHeader *message)
Function called by the transport for each received message.
struct GNUNET_PeerIdentity peer
For which peer is this an address?
void * GNUNET_CONTAINER_multipeermap_get(const struct GNUNET_CONTAINER_MultiPeerMap *map, const struct GNUNET_PeerIdentity *key)
Given a key find a value in the map matching the key.
#define GNUNET_log(kind,...)
#define GNUNET_YES
Definition: gnunet_common.h:80
const char * GNUNET_i2s(const struct GNUNET_PeerIdentity *pid)
Convert a peer identity to a string (for printing debug messages).
Time for relative time used by GNUnet, in microseconds.
Here is the call graph for this function:
Here is the caller graph for this function:

◆ GST_manipulation_manipulate_metrics()

void GST_manipulation_manipulate_metrics ( const struct GNUNET_HELLO_Address address,
struct GNUNET_ATS_Session session,
struct GNUNET_ATS_Properties prop 
)

Function that will be called to manipulate ATS information according to current manipulation settings.

Parameters
addressbinary address
sessionthe session
prop[IN|OUT]metrics to modify

Definition at line 355 of file gnunet-service-transport_manipulation.c.

References GNUNET_CONTAINER_multipeermap_get(), GNUNET_HELLO_Address::peer, TM_Peer::peer, and TM_Peer::properties.

Referenced by GST_ats_update_delay(), GST_ats_update_distance(), and GST_ats_update_utilization().

358 {
359  const struct GNUNET_PeerIdentity *peer = &address->peer;
360  struct TM_Peer *tmp;
361 
363  peer);
364  if (NULL != tmp)
365  *prop = tmp->properties;
366 }
static struct GNUNET_CONTAINER_MultiPeerMap * peers
Hashmap contain all peers currently manipulated.
Struct containing information about manipulations to a specific peer.
struct GNUNET_ATS_Properties properties
Manipulated properties to use for this peer.
struct GNUNET_TESTBED_Peer * peer
The peer associated with this model.
struct GNUNET_PeerIdentity peer
For which peer is this an address?
The identity of the host (wraps the signing key of the peer).
void * GNUNET_CONTAINER_multipeermap_get(const struct GNUNET_CONTAINER_MultiPeerMap *map, const struct GNUNET_PeerIdentity *key)
Given a key find a value in the map matching the key.
Here is the call graph for this function:
Here is the caller graph for this function:

◆ GST_manipulation_peer_disconnect()

void GST_manipulation_peer_disconnect ( const struct GNUNET_PeerIdentity peer)

Notify manipulation about disconnect so it can discard queued messages.

Parameters
peerthe disconnecting peer

Definition at line 456 of file gnunet-service-transport_manipulation.c.

References DelayQueueEntry::cont, DelayQueueEntry::cont_cls, generic_dqe_head, GNUNET_CONTAINER_DLL_remove, GNUNET_CONTAINER_multipeermap_get(), GNUNET_free, GNUNET_SCHEDULER_add_at(), GNUNET_SCHEDULER_cancel(), GNUNET_SYSERR, DelayQueueEntry::id, DelayQueueEntry::msg_size, DelayQueueEntry::next, send_delayed(), TM_Peer::send_head, TM_Peer::send_tail, and DelayQueueEntry::sent_at.

Referenced by neighbours_disconnect_notification().

457 {
458  struct TM_Peer *tmp;
459  struct DelayQueueEntry *dqe;
460  struct DelayQueueEntry *next;
461 
463  peer);
464  if (NULL != tmp)
465  {
466  while (NULL != (dqe = tmp->send_head))
467  {
469  tmp->send_tail,
470  dqe);
471  if (NULL != dqe->cont)
472  dqe->cont (dqe->cont_cls,
474  dqe->msg_size,
475  0);
476  GNUNET_free(dqe);
477  }
478  }
479  next = generic_dqe_head;
480  while (NULL != (dqe = next))
481  {
482  next = dqe->next;
483  if (0 == memcmp (peer,
484  &dqe->id,
485  sizeof (dqe->id)))
486  {
489  dqe);
490  if (NULL != dqe->cont)
491  dqe->cont (dqe->cont_cls,
493  dqe->msg_size,
494  0);
495  GNUNET_free(dqe);
496  }
497  }
498  if (NULL != generic_send_delay_task)
499  {
502  if (NULL != generic_dqe_head)
505  &send_delayed,
507  }
508 }
#define GNUNET_CONTAINER_DLL_remove(head, tail, element)
Remove an element from a DLL.
Entry in the delay queue for an outbound delayed message.
struct DelayQueueEntry * send_head
Send queue DLL head.
struct DelayQueueEntry * send_tail
Send queue DLL tail.
void * cont_cls
Transports send continuation cls.
GST_NeighbourSendContinuation cont
Transports send continuation.
struct DelayQueueEntry * next
Previous in DLL.
static struct GNUNET_CONTAINER_MultiPeerMap * peers
Hashmap contain all peers currently manipulated.
Struct containing information about manipulations to a specific peer.
static void send_delayed(void *cls)
We have delayed transmission, now it is time to send the message.
#define GNUNET_SYSERR
Definition: gnunet_common.h:79
static struct DelayQueueEntry * generic_dqe_head
DLL head for delayed messages based on general delay.
static struct GNUNET_SCHEDULER_Task * generic_send_delay_task
Task to schedule delayed sending based on general delay.
void * GNUNET_CONTAINER_multipeermap_get(const struct GNUNET_CONTAINER_MultiPeerMap *map, const struct GNUNET_PeerIdentity *key)
Given a key find a value in the map matching the key.
struct GNUNET_TIME_Absolute sent_at
Absolute time when to send.
static struct DelayQueueEntry * generic_dqe_tail
DLL tail for delayed messages based on general delay.
struct GNUNET_SCHEDULER_Task * GNUNET_SCHEDULER_add_at(struct GNUNET_TIME_Absolute at, GNUNET_SCHEDULER_TaskCallback task, void *task_cls)
Schedule a new task to be run at the specified time.
Definition: scheduler.c:1223
struct GNUNET_PeerIdentity id
Peer ID.
#define GNUNET_free(ptr)
Wrapper around free.
void * GNUNET_SCHEDULER_cancel(struct GNUNET_SCHEDULER_Task *task)
Cancel the task with the specified identifier.
Definition: scheduler.c:965
Here is the call graph for this function:
Here is the caller graph for this function:

◆ GST_manipulation_init()

void GST_manipulation_init ( void  )

Initialize traffic manipulation.

Definition at line 415 of file gnunet-service-transport_manipulation.c.

References delay, TM_Peer::delay_in, TM_Peer::delay_out, GNUNET_CONFIGURATION_get_value_time(), GNUNET_CONTAINER_multipeermap_create(), GNUNET_ERROR_TYPE_INFO, GNUNET_log, GNUNET_NO, GNUNET_OK, GNUNET_STRINGS_relative_time_to_string(), GNUNET_YES, GST_cfg, and GNUNET_TIME_Relative::rel_value_us.

Referenced by run().

416 {
418 
419  if ( (GNUNET_OK ==
421  "transport",
422  "MANIPULATE_DELAY_IN",
423  &delay)) &&
424  (delay.rel_value_us > 0) )
425  {
427  "Delaying inbound traffic for %s\n",
429  GNUNET_YES));
430  delay_in = delay;
431  }
432  if ( (GNUNET_OK ==
434  "transport",
435  "MANIPULATE_DELAY_OUT",
436  &delay)) &&
437  (delay.rel_value_us > 0) )
438  {
440  "Delaying outbound traffic for %s\n",
442  GNUNET_YES));
443  delay_out = delay;
444  }
446  GNUNET_NO);
447 }
static struct GNUNET_TIME_Relative delay_in
Inbound delay to apply to all peers.
int GNUNET_CONFIGURATION_get_value_time(const struct GNUNET_CONFIGURATION_Handle *cfg, const char *section, const char *option, struct GNUNET_TIME_Relative *time)
Get a configuration value that should be a relative time.
uint64_t rel_value_us
The actual value.
#define GNUNET_NO
Definition: gnunet_common.h:81
#define GNUNET_OK
Named constants for return values.
Definition: gnunet_common.h:78
struct GNUNET_CONTAINER_MultiPeerMap * GNUNET_CONTAINER_multipeermap_create(unsigned int len, int do_not_copy_keys)
Create a multi peer map (hash map for public keys of peers).
static struct GNUNET_CONTAINER_MultiPeerMap * peers
Hashmap contain all peers currently manipulated.
const char * GNUNET_STRINGS_relative_time_to_string(struct GNUNET_TIME_Relative delta, int do_round)
Give relative time in human-readable fancy format.
Definition: strings.c:727
static struct GNUNET_TIME_Relative delay
When should dkg communication start?
static struct GNUNET_TIME_Relative delay_out
Outbound delay to apply to all peers.
#define GNUNET_log(kind,...)
#define GNUNET_YES
Definition: gnunet_common.h:80
static const struct GNUNET_CONFIGURATION_Handle * GST_cfg
Configuration handle.
Time for relative time used by GNUnet, in microseconds.
Here is the call graph for this function:
Here is the caller graph for this function:

◆ GST_manipulation_stop()

void GST_manipulation_stop ( void  )

Stop traffic manipulation.

Definition at line 557 of file gnunet-service-transport_manipulation.c.

References DelayQueueEntry::cont, DelayQueueEntry::cont_cls, free_tmps(), GNUNET_CONTAINER_DLL_remove, GNUNET_CONTAINER_multipeermap_destroy(), GNUNET_CONTAINER_multipeermap_iterate(), GNUNET_free, GNUNET_SCHEDULER_cancel(), GNUNET_SYSERR, and DelayQueueEntry::msg_size.

Referenced by shutdown_task().

558 {
559  struct DelayQueueEntry *cur;
560 
562  &free_tmps,
563  NULL);
565  peers = NULL;
566  while (NULL != (cur = generic_dqe_head))
567  {
570  cur);
571  if (NULL != cur->cont)
572  cur->cont (cur->cont_cls,
574  cur->msg_size,
575  0);
576  GNUNET_free (cur);
577  }
578  if (NULL != generic_send_delay_task)
579  {
582  }
583 }
#define GNUNET_CONTAINER_DLL_remove(head, tail, element)
Remove an element from a DLL.
Entry in the delay queue for an outbound delayed message.
void * cont_cls
Transports send continuation cls.
static int free_tmps(void *cls, const struct GNUNET_PeerIdentity *key, void *value)
Free manipulation information about a peer.
void GNUNET_CONTAINER_multipeermap_destroy(struct GNUNET_CONTAINER_MultiPeerMap *map)
Destroy a hash map.
GST_NeighbourSendContinuation cont
Transports send continuation.
static struct GNUNET_CONTAINER_MultiPeerMap * peers
Hashmap contain all peers currently manipulated.
#define GNUNET_SYSERR
Definition: gnunet_common.h:79
int GNUNET_CONTAINER_multipeermap_iterate(struct GNUNET_CONTAINER_MultiPeerMap *map, GNUNET_CONTAINER_PeerMapIterator it, void *it_cls)
Iterate over all entries in the map.
static struct DelayQueueEntry * generic_dqe_head
DLL head for delayed messages based on general delay.
static struct GNUNET_SCHEDULER_Task * generic_send_delay_task
Task to schedule delayed sending based on general delay.
static struct DelayQueueEntry * generic_dqe_tail
DLL tail for delayed messages based on general delay.
#define GNUNET_free(ptr)
Wrapper around free.
void * GNUNET_SCHEDULER_cancel(struct GNUNET_SCHEDULER_Task *task)
Cancel the task with the specified identifier.
Definition: scheduler.c:965
Here is the call graph for this function:
Here is the caller graph for this function: