struct GNUNET_TESTING_Daemon *second_daemon,
const char *emsg)
{
- char *firstc = strdup (GNUNET_i2s (first));
- char *secondc = strdup (GNUNET_i2s (second));
+ char *firstc = GNUNET_strdup (GNUNET_i2s (first));
+ char *secondc = GNUNET_strdup (GNUNET_i2s (second));
connected++;
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Connected peers `%s'<->`%s' (%i/%i)\n",
addr[0].plugin = "test";
addr[0].session = NULL;
- addr[0].addr = strdup ("test");
+ addr[0].addr = GNUNET_strdup ("test");
addr[0].addr_len = 4;
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Testing address creation\n");
{
if (GNUNET_OS_check_helper_binary (filenameloopback) == GNUNET_YES)
{
- absolute_filename = strdup (filenameloopback);
+ absolute_filename = GNUNET_strdup (filenameloopback);
}
else
{
if (ntohl (hdr->num) % 5000 == 0)
{
struct PeerContext *p = cls;
- char *ps = strdup (GNUNET_i2s (&p->id));
+ char *ps = GNUNET_strdup (GNUNET_i2s (&p->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Peer %u (`%s') got message %u of size %u from peer (`%s')\n",
if (n % 5000 == 0)
{
- char *receiver_s = strdup (GNUNET_i2s (&receiver->id));
+ char *receiver_s = GNUNET_strdup (GNUNET_i2s (&receiver->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Sending message of size %u from peer %u (`%4s') -> peer %u (`%s') !\n",
static void
testing_connect_cb (struct PeerContext *p1, struct PeerContext *p2, void *cls)
{
- char *p1_c = strdup (GNUNET_i2s (&p1->id));
+ char *p1_c = GNUNET_strdup (GNUNET_i2s (&p1->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Peers connected: %u (%s) <-> %u (%s)\n",
p1->no, p1_c, p2->no, GNUNET_i2s (&p2->id));
sender = p2;
receiver = p1;
- char *sender_c = strdup (GNUNET_i2s (&sender->id));
+ char *sender_c = GNUNET_strdup (GNUNET_i2s (&sender->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Test tries to send from %u (%s) -> peer %u (%s)\n", sender->no,
t = p2;
GNUNET_assert (t != NULL);
- char *ps = strdup (GNUNET_i2s (&p->id));
+ char *ps = GNUNET_strdup (GNUNET_i2s (&p->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Peer %u (`%4s') received message of type %d and size %u size from peer %u (`%4s')!\n",
hdr->size = htons (sizeof (struct GNUNET_MessageHeader));
hdr->type = htons (MTYPE);
}
- char *ps = strdup (GNUNET_i2s (&p2->id));
+ char *ps = GNUNET_strdup (GNUNET_i2s (&p2->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Peer %u (`%4s') sending message with type %u and size %u bytes to peer %u (`%4s')\n",
if ((tc->reason & GNUNET_SCHEDULER_REASON_SHUTDOWN) != 0)
return;
- char *receiver_s = strdup (GNUNET_i2s (&p1->id));
+ char *receiver_s = GNUNET_strdup (GNUNET_i2s (&p1->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Sending message from peer %u (`%4s') -> peer %u (`%s') !\n",
t = p2;
GNUNET_assert (t != NULL);
- char *ps = strdup (GNUNET_i2s (&p->id));
+ char *ps = GNUNET_strdup (GNUNET_i2s (&p->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Peer %u (`%4s'): peer %u (`%s') connected to me!\n", p->no, ps,
notify_disconnect (void *cls, const struct GNUNET_PeerIdentity *peer)
{
struct PeerContext *p = cls;
- char *ps = strdup (GNUNET_i2s (&p->id));
+ char *ps = GNUNET_strdup (GNUNET_i2s (&p->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Peer %u (`%4s'): peer (`%s') disconnected from me!\n", p->no, ps,
testing_connect_cb (struct PeerContext *p1, struct PeerContext *p2, void *cls)
{
cc = NULL;
- char *p1_c = strdup (GNUNET_i2s (&p1->id));
+ char *p1_c = GNUNET_strdup (GNUNET_i2s (&p1->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Peers connected: %u (%s) <-> %u (%s)\n",
p1->no, p1_c, p2->no, GNUNET_i2s (&p2->id));
if (started != 2)
return;
- char *sender_c = strdup (GNUNET_i2s (&p1->id));
+ char *sender_c = GNUNET_strdup (GNUNET_i2s (&p1->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Test tries to connect peer %u (`%s') -> peer %u (`%s')\n",
t = p2;
GNUNET_assert (t != NULL);
- char *ps = strdup (GNUNET_i2s (&p->id));
+ char *ps = GNUNET_strdup (GNUNET_i2s (&p->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Peer %u (`%4s') received message of type %d and size %u size from peer %u (`%4s')!\n",
hdr->size = htons (sizeof (struct GNUNET_MessageHeader));
hdr->type = htons (MTYPE);
}
- char *ps = strdup (GNUNET_i2s (&p2->id));
+ char *ps = GNUNET_strdup (GNUNET_i2s (&p2->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Peer %u (`%4s') sending message with type %u and size %u bytes to peer %u (`%4s')\n",
if ((tc->reason & GNUNET_SCHEDULER_REASON_SHUTDOWN) != 0)
return;
- char *receiver_s = strdup (GNUNET_i2s (&p1->id));
+ char *receiver_s = GNUNET_strdup (GNUNET_i2s (&p1->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Sending message from peer %u (`%4s') -> peer %u (`%s') !\n",
t = p2;
GNUNET_assert (t != NULL);
- char *ps = strdup (GNUNET_i2s (&p->id));
+ char *ps = GNUNET_strdup (GNUNET_i2s (&p->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Peer %u (`%4s'): peer %u (`%s') connected to me!\n", p->no, ps,
notify_disconnect (void *cls, const struct GNUNET_PeerIdentity *peer)
{
struct PeerContext *p = cls;
- char *ps = strdup (GNUNET_i2s (&p->id));
+ char *ps = GNUNET_strdup (GNUNET_i2s (&p->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Peer %u (`%4s'): peer (`%s') disconnected from me!\n", p->no, ps,
GNUNET_TRANSPORT_TESTING_connect_peers_cancel (tth, cc1);
}
- char *p1_c = strdup (GNUNET_i2s (&p1->id));
+ char *p1_c = GNUNET_strdup (GNUNET_i2s (&p1->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Peers connected: %u (%s) <-> %u (%s)\n",
p1->no, p1_c, p2->no, GNUNET_i2s (&p2->id));
if (started != 2)
return;
- char *sender_c = strdup (GNUNET_i2s (&p1->id));
+ char *sender_c = GNUNET_strdup (GNUNET_i2s (&p1->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Test tries to connect peer %u (`%s') <-> peer %u (`%s')\n",
notify_disconnect (void *cls, const struct GNUNET_PeerIdentity *peer)
{
struct PeerContext *p = cls;
- char *ps = strdup (GNUNET_i2s (&p->id));
+ char *ps = GNUNET_strdup (GNUNET_i2s (&p->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Peer %u (`%4s'): peer (`%s') disconnected from me!\n", p->no, ps,
t = p2;
GNUNET_assert (t != NULL);
- char *ps = strdup (GNUNET_i2s (&p->id));
+ char *ps = GNUNET_strdup (GNUNET_i2s (&p->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Peer %u (`%4s') received message of type %d and size %u size from peer %u (`%4s')!\n",
hdr->size = htons (sizeof (struct GNUNET_MessageHeader));
hdr->type = htons (MTYPE);
}
- char *ps = strdup (GNUNET_i2s (&p2->id));
+ char *ps = GNUNET_strdup (GNUNET_i2s (&p2->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Peer %u (`%4s') sending message with type %u and size %u bytes to peer %u (`%4s')\n",
if ((tc->reason & GNUNET_SCHEDULER_REASON_SHUTDOWN) != 0)
return;
- char *receiver_s = strdup (GNUNET_i2s (&p1->id));
+ char *receiver_s = GNUNET_strdup (GNUNET_i2s (&p1->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Sending message from peer %u (`%4s') -> peer %u (`%s') !\n",
t = p2;
GNUNET_assert (t != NULL);
- char *ps = strdup (GNUNET_i2s (&p->id));
+ char *ps = GNUNET_strdup (GNUNET_i2s (&p->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Peer %u (`%4s'): peer %u (`%s') connected to me!\n", p->no, ps,
testing_connect_cb (struct PeerContext *p1, struct PeerContext *p2, void *cls)
{
cc = NULL;
- char *p1_c = strdup (GNUNET_i2s (&p1->id));
+ char *p1_c = GNUNET_strdup (GNUNET_i2s (&p1->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Peers connected: %u (%s) <-> %u (%s)\n",
p1->no, p1_c, p2->no, GNUNET_i2s (&p2->id));
if (started != 2)
return;
- char *sender_c = strdup (GNUNET_i2s (&p1->id));
+ char *sender_c = GNUNET_strdup (GNUNET_i2s (&p1->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Test tries to connect peer %u (`%s') -> peer %u (`%s')\n",
testing_connect_cb (struct PeerContext *p1, struct PeerContext *p2, void *cls)
{
cc = NULL;
- char *p1_c = strdup (GNUNET_i2s (&p1->id));
+ char *p1_c = GNUNET_strdup (GNUNET_i2s (&p1->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Peers connected: %s <-> %s\n", p1_c,
GNUNET_i2s (&p2->id));
if (ntohl (hdr->num) % 5000 == 0)
{
struct PeerContext *p = cls;
- char *ps = strdup (GNUNET_i2s (&p->id));
+ char *ps = GNUNET_strdup (GNUNET_i2s (&p->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Peer %u (`%s') got message %u of size %u from peer (`%s')\n",
if (n % 5000 == 0)
{
- char *receiver_s = strdup (GNUNET_i2s (&receiver->id));
+ char *receiver_s = GNUNET_strdup (GNUNET_i2s (&receiver->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Sending message of size %u from peer %u (`%4s') -> peer %u (`%s') !\n",
static void
testing_connect_cb (struct PeerContext *p1, struct PeerContext *p2, void *cls)
{
- char *p1_c = strdup (GNUNET_i2s (&p1->id));
+ char *p1_c = GNUNET_strdup (GNUNET_i2s (&p1->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Peers connected: %u (%s) <-> %u (%s)\n",
p1->no, p1_c, p2->no, GNUNET_i2s (&p2->id));
sender = p2;
receiver = p1;
- char *sender_c = strdup (GNUNET_i2s (&sender->id));
+ char *sender_c = GNUNET_strdup (GNUNET_i2s (&sender->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Test triest to send from %u (%s) -> peer %u (%s)\n", sender->no,
t = p2;
GNUNET_assert (t != NULL);
- char *ps = strdup (GNUNET_i2s (&p->id));
+ char *ps = GNUNET_strdup (GNUNET_i2s (&p->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Peer %u (`%4s') received message of type %d and size %u size from peer %u (`%4s')!\n",
p->no, ps, ntohs (message->type), ntohs (message->size), t->no,
hdr->size = htons (sizeof (struct GNUNET_MessageHeader));
hdr->type = htons (MTYPE);
}
- char *ps = strdup (GNUNET_i2s (&p2->id));
+ char *ps = GNUNET_strdup (GNUNET_i2s (&p2->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Peer %u (`%4s') sending message with type %u and size %u bytes to peer %u (`%4s')\n",
if ((tc->reason & GNUNET_SCHEDULER_REASON_SHUTDOWN) != 0)
return;
- char *receiver_s = strdup (GNUNET_i2s (&p1->id));
+ char *receiver_s = GNUNET_strdup (GNUNET_i2s (&p1->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Sending message from peer %u (`%4s') -> peer %u (`%s') !\n",
t = p2;
GNUNET_assert (t != NULL);
- char *ps = strdup (GNUNET_i2s (&p->id));
+ char *ps = GNUNET_strdup (GNUNET_i2s (&p->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Peer %u (`%4s'): peer %u (`%s') connected to me!\n", p->no, ps,
struct PeerContext *p = cls;
- char *ps = strdup (GNUNET_i2s (&p->id));
+ char *ps = GNUNET_strdup (GNUNET_i2s (&p->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Peer %u (`%4s'): peer (`%s') disconnected from me!\n", p->no, ps,
GNUNET_i2s (peer));
testing_connect_cb (struct PeerContext *p1, struct PeerContext *p2, void *cls)
{
cc = NULL;
- char *p1_c = strdup (GNUNET_i2s (&p1->id));
+ char *p1_c = GNUNET_strdup (GNUNET_i2s (&p1->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Peers connected: %u (%s) <-> %u (%s)\n",
p1->no, p1_c, p2->no, GNUNET_i2s (&p2->id));
if (started != 2)
return;
- char *sender_c = strdup (GNUNET_i2s (&p1->id));
+ char *sender_c = GNUNET_strdup (GNUNET_i2s (&p1->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Test tries to connect peer %u (`%s') -> peer %u (`%s')\n",
p1->no, sender_c, p2->no, GNUNET_i2s (&p2->id));
t = p2;
GNUNET_assert (t != NULL);
- char *ps = strdup (GNUNET_i2s (&p->id));
+ char *ps = GNUNET_strdup (GNUNET_i2s (&p->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Peer %u (`%4s') received message of type %d and size %u size from peer %u (`%4s')!\n",
p->no, ps, ntohs (message->type), ntohs (message->size), t->no,
hdr->size = htons (sizeof (struct GNUNET_MessageHeader));
hdr->type = htons (MTYPE);
}
- char *ps = strdup (GNUNET_i2s (&p2->id));
+ char *ps = GNUNET_strdup (GNUNET_i2s (&p2->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Peer %u (`%4s') sending message with type %u and size %u bytes to peer %u (`%4s')\n",
if ((tc->reason & GNUNET_SCHEDULER_REASON_SHUTDOWN) != 0)
return;
- char *receiver_s = strdup (GNUNET_i2s (&p1->id));
+ char *receiver_s = GNUNET_strdup (GNUNET_i2s (&p1->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Sending message from peer %u (`%4s') -> peer %u (`%s') !\n",
t = p2;
GNUNET_assert (t != NULL);
- char *ps = strdup (GNUNET_i2s (&p->id));
+ char *ps = GNUNET_strdup (GNUNET_i2s (&p->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Peer %u (`%4s'): peer %u (`%s') connected to me!\n", p->no, ps,
struct PeerContext *p = cls;
- char *ps = strdup (GNUNET_i2s (&p->id));
+ char *ps = GNUNET_strdup (GNUNET_i2s (&p->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Peer %u (`%4s'): peer (`%s') disconnected from me!\n", p->no, ps,
GNUNET_i2s (peer));
testing_connect_cb (struct PeerContext *p1, struct PeerContext *p2, void *cls)
{
cc = NULL;
- char *p1_c = strdup (GNUNET_i2s (&p1->id));
+ char *p1_c = GNUNET_strdup (GNUNET_i2s (&p1->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Peers connected: %u (%s) <-> %u (%s)\n",
p1->no, p1_c, p2->no, GNUNET_i2s (&p2->id));
if (started != 2)
return;
- char *sender_c = strdup (GNUNET_i2s (&p1->id));
+ char *sender_c = GNUNET_strdup (GNUNET_i2s (&p1->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Test tries to connect peer %u (`%s') -> peer %u (`%s')\n",
p1->no, sender_c, p2->no, GNUNET_i2s (&p2->id));
testing_connect_cb (struct PeerContext *p1, struct PeerContext *p2, void *cls)
{
cc = NULL;
- char *p1_c = strdup (GNUNET_i2s (&p1->id));
+ char *p1_c = GNUNET_strdup (GNUNET_i2s (&p1->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Peers connected: %s <-> %s\n", p1_c,
GNUNET_i2s (&p2->id));
if (started != 2)
return;
- char *sender_c = strdup (GNUNET_i2s (&p1->id));
+ char *sender_c = GNUNET_strdup (GNUNET_i2s (&p1->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Test tries to connect peer %u (`%s') -> peer %u (`%s')\n",
static void
testing_connect_cb (struct PeerContext *p1, struct PeerContext *p2, void *cls)
{
- char *p1_c = strdup (GNUNET_i2s (&p1->id));
+ char *p1_c = GNUNET_strdup (GNUNET_i2s (&p1->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Peers connected: %s <-> %s\n", p1_c,
GNUNET_i2s (&p2->id));
static void
testing_connect_cb (struct PeerContext *p1, struct PeerContext *p2, void *cls)
{
- char *p1_c = strdup (GNUNET_i2s (&p1->id));
+ char *p1_c = GNUNET_strdup (GNUNET_i2s (&p1->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Peers connected: %s <-> %s\n", p1_c,
GNUNET_i2s (&p2->id));
static void
testing_connect_cb (struct PeerContext *p1, struct PeerContext *p2, void *cls)
{
- char *ps = strdup (GNUNET_i2s (&p1->id));
+ char *ps = GNUNET_strdup (GNUNET_i2s (&p1->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Peer %u (`%4s') connected to peer %u (`%s')!\n", p1->no, ps,
if (started != 2)
return;
- char *sender_c = strdup (GNUNET_i2s (&p1->id));
+ char *sender_c = GNUNET_strdup (GNUNET_i2s (&p1->id));
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Test tries to connect peer %u (`%s') -> peer %u (`%s')\n",