/**
* The client handle to the master controller
*/
- struct GNUNET_SERVER_Client *client;
+ struct GNUNET_SERVER_Client *mc;
/**
* The name of the barrier
mq = GNUNET_malloc (sizeof (struct MessageQueue));
mq->msg = msg;
+ LOG_DEBUG ("Queueing message of type %u, size %u for sending\n",
+ ntohs (msg->type), ntohs (msg->size));
GNUNET_CONTAINER_DLL_insert_tail (ctx->mq_head, ctx->mq_tail, mq);
if (NULL == ctx->tx)
ctx->tx = GNUNET_SERVER_notify_transmit_ready (client, ntohs (msg->size),
cleanup_clientctx (ctx);
}
GNUNET_free (barrier->name);
- GNUNET_SERVER_client_drop (barrier->client);
+ GNUNET_SERVER_client_drop (barrier->mc);
GNUNET_free (barrier);
}
send_barrier_status_msg (struct Barrier *barrier, const char *emsg)
{
GNUNET_assert (0 != barrier->status);
- send_client_status_msg (barrier->client, barrier->name,
- barrier->status, emsg);
+ send_client_status_msg (barrier->mc, barrier->name, barrier->status, emsg);
}
GNUNET_SERVER_client_keep (client);
client_ctx->barrier = barrier;
GNUNET_CONTAINER_DLL_insert_tail (barrier->head, barrier->tail, client_ctx);
+ GNUNET_SERVER_client_set_user_context (client, client_ctx);
}
barrier->nreached++;
if ((barrier->num_wbarriers_reached == barrier->num_wbarriers)
(void) memcpy (&barrier->hash, &hash, sizeof (struct GNUNET_HashCode));
barrier->quorum = msg->quorum;
barrier->name = name;
- barrier->client = client;
+ barrier->mc = client;
GNUNET_SERVER_client_keep (client);
GNUNET_assert (GNUNET_OK ==
GNUNET_CONTAINER_multihashmap_put (barrier_map,