aboutsummaryrefslogtreecommitdiff
path: root/src/testbed/gnunet-service-testbed_barriers.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/testbed/gnunet-service-testbed_barriers.c')
-rw-r--r--src/testbed/gnunet-service-testbed_barriers.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/testbed/gnunet-service-testbed_barriers.c b/src/testbed/gnunet-service-testbed_barriers.c
index d8545ad04..b994a7d15 100644
--- a/src/testbed/gnunet-service-testbed_barriers.c
+++ b/src/testbed/gnunet-service-testbed_barriers.c
@@ -282,7 +282,7 @@ transmit_ready_cb (void *cls, size_t size, void *buf)
282 msg = mq->msg; 282 msg = mq->msg;
283 wrote = ntohs (msg->size); 283 wrote = ntohs (msg->size);
284 GNUNET_assert (size >= wrote); 284 GNUNET_assert (size >= wrote);
285 (void) memcpy (buf, msg, wrote); 285 GNUNET_memcpy (buf, msg, wrote);
286 GNUNET_CONTAINER_DLL_remove (ctx->mq_head, ctx->mq_tail, mq); 286 GNUNET_CONTAINER_DLL_remove (ctx->mq_head, ctx->mq_tail, mq);
287 GNUNET_free (mq->msg); 287 GNUNET_free (mq->msg);
288 GNUNET_free (mq); 288 GNUNET_free (mq);
@@ -418,9 +418,9 @@ send_client_status_msg (struct GNUNET_SERVER_Client *client,
418 msg->header.type = htons (GNUNET_MESSAGE_TYPE_TESTBED_BARRIER_STATUS); 418 msg->header.type = htons (GNUNET_MESSAGE_TYPE_TESTBED_BARRIER_STATUS);
419 msg->status = htons (status); 419 msg->status = htons (status);
420 msg->name_len = htons ((uint16_t) name_len); 420 msg->name_len = htons ((uint16_t) name_len);
421 (void) memcpy (msg->data, name, name_len); 421 GNUNET_memcpy (msg->data, name, name_len);
422 if (NULL != emsg) 422 if (NULL != emsg)
423 (void) memcpy (msg->data + name_len + 1, emsg, strlen (emsg)); 423 GNUNET_memcpy (msg->data + name_len + 1, emsg, strlen (emsg));
424 GST_queue_message (client, &msg->header); 424 GST_queue_message (client, &msg->header);
425} 425}
426 426
@@ -481,7 +481,7 @@ handle_barrier_wait (void *cls, struct GNUNET_SERVER_Client *client,
481 name_len = msize - sizeof (struct GNUNET_TESTBED_BarrierWait); 481 name_len = msize - sizeof (struct GNUNET_TESTBED_BarrierWait);
482 name = GNUNET_malloc (name_len + 1); 482 name = GNUNET_malloc (name_len + 1);
483 name[name_len] = '\0'; 483 name[name_len] = '\0';
484 (void) memcpy (name, msg->name, name_len); 484 GNUNET_memcpy (name, msg->name, name_len);
485 LOG_DEBUG ("Received BARRIER_WAIT for barrier `%s'\n", name); 485 LOG_DEBUG ("Received BARRIER_WAIT for barrier `%s'\n", name);
486 GNUNET_CRYPTO_hash (name, name_len, &key); 486 GNUNET_CRYPTO_hash (name, name_len, &key);
487 GNUNET_free (name); 487 GNUNET_free (name);
@@ -734,7 +734,7 @@ GST_handle_barrier_init (void *cls, struct GNUNET_SERVER_Client *client,
734 msg = (const struct GNUNET_TESTBED_BarrierInit *) message; 734 msg = (const struct GNUNET_TESTBED_BarrierInit *) message;
735 name_len = (size_t) msize - sizeof (struct GNUNET_TESTBED_BarrierInit); 735 name_len = (size_t) msize - sizeof (struct GNUNET_TESTBED_BarrierInit);
736 name = GNUNET_malloc (name_len + 1); 736 name = GNUNET_malloc (name_len + 1);
737 (void) memcpy (name, msg->name, name_len); 737 GNUNET_memcpy (name, msg->name, name_len);
738 GNUNET_CRYPTO_hash (name, name_len, &hash); 738 GNUNET_CRYPTO_hash (name, name_len, &hash);
739 LOG_DEBUG ("Received BARRIER_INIT for barrier `%s'\n", name); 739 LOG_DEBUG ("Received BARRIER_INIT for barrier `%s'\n", name);
740 if (GNUNET_YES == GNUNET_CONTAINER_multihashmap_contains (barrier_map, &hash)) 740 if (GNUNET_YES == GNUNET_CONTAINER_multihashmap_contains (barrier_map, &hash))
@@ -747,7 +747,7 @@ GST_handle_barrier_init (void *cls, struct GNUNET_SERVER_Client *client,
747 return; 747 return;
748 } 748 }
749 barrier = GNUNET_new (struct Barrier); 749 barrier = GNUNET_new (struct Barrier);
750 (void) memcpy (&barrier->hash, &hash, sizeof (struct GNUNET_HashCode)); 750 GNUNET_memcpy (&barrier->hash, &hash, sizeof (struct GNUNET_HashCode));
751 barrier->quorum = msg->quorum; 751 barrier->quorum = msg->quorum;
752 barrier->name = name; 752 barrier->name = name;
753 barrier->mc = client; 753 barrier->mc = client;
@@ -836,7 +836,7 @@ GST_handle_barrier_cancel (void *cls, struct GNUNET_SERVER_Client *client,
836 msg = (const struct GNUNET_TESTBED_BarrierCancel *) message; 836 msg = (const struct GNUNET_TESTBED_BarrierCancel *) message;
837 name_len = msize - sizeof (struct GNUNET_TESTBED_BarrierCancel); 837 name_len = msize - sizeof (struct GNUNET_TESTBED_BarrierCancel);
838 name = GNUNET_malloc (name_len + 1); 838 name = GNUNET_malloc (name_len + 1);
839 (void) memcpy (name, msg->name, name_len); 839 GNUNET_memcpy (name, msg->name, name_len);
840 GNUNET_CRYPTO_hash (name, name_len, &hash); 840 GNUNET_CRYPTO_hash (name, name_len, &hash);
841 if (GNUNET_NO == GNUNET_CONTAINER_multihashmap_contains (barrier_map, &hash)) 841 if (GNUNET_NO == GNUNET_CONTAINER_multihashmap_contains (barrier_map, &hash))
842 { 842 {