From 344f48e48e8d4f1ea631f29d8fb3ae0faf3d7ef0 Mon Sep 17 00:00:00 2001 From: Christian Grothoff Date: Fri, 25 Apr 2014 07:59:45 +0000 Subject: -indent, doxygen --- src/core/core_api.c | 6 ++++-- src/core/gnunet-service-core_clients.c | 24 +++++++++++++----------- src/core/gnunet-service-core_kx.c | 6 ++++-- src/core/gnunet-service-core_sessions.c | 6 ++++-- src/core/gnunet-service-core_typemap.c | 4 ++-- 5 files changed, 27 insertions(+), 19 deletions(-) (limited to 'src/core') diff --git a/src/core/core_api.c b/src/core/core_api.c index 7818a60a3..21bc758ff 100644 --- a/src/core/core_api.c +++ b/src/core/core_api.c @@ -191,7 +191,7 @@ struct ControlMessage GNUNET_CORE_ControlContinuation cont; /** - * Closure for 'cont'. + * Closure for @e cont. */ void *cont_cls; @@ -761,6 +761,7 @@ main_notify_handler (void *cls, int trigger; uint16_t msize; uint16_t et; + if (NULL == msg) { LOG (GNUNET_ERROR_TYPE_INFO, @@ -795,7 +796,8 @@ main_notify_handler (void *cls, { /* mark so we don't call init on reconnect */ h->init = NULL; - LOG (GNUNET_ERROR_TYPE_DEBUG, "Connected to core service of peer `%s'.\n", + LOG (GNUNET_ERROR_TYPE_DEBUG, + "Connected to core service of peer `%s'.\n", GNUNET_i2s (&h->me)); init (h->cls, &h->me); } diff --git a/src/core/gnunet-service-core_clients.c b/src/core/gnunet-service-core_clients.c index 634959674..c099987a9 100644 --- a/src/core/gnunet-service-core_clients.c +++ b/src/core/gnunet-service-core_clients.c @@ -259,10 +259,11 @@ send_to_all_clients (const struct GNUNET_PeerIdentity *partner, * * @param cls unused * @param client new client that sent INIT - * @param message the 'struct InitMessage' (presumably) + * @param message the `struct InitMessage` (presumably) */ static void -handle_client_init (void *cls, struct GNUNET_SERVER_Client *client, +handle_client_init (void *cls, + struct GNUNET_SERVER_Client *client, const struct GNUNET_MessageHeader *message) { const struct InitMessage *im; @@ -328,10 +329,11 @@ handle_client_init (void *cls, struct GNUNET_SERVER_Client *client, * * @param cls unused * @param client new client that sent CORE_SEND_REQUEST - * @param message the 'struct SendMessageRequest' (presumably) + * @param message the `struct SendMessageRequest` (presumably) */ static void -handle_client_send_request (void *cls, struct GNUNET_SERVER_Client *client, +handle_client_send_request (void *cls, + struct GNUNET_SERVER_Client *client, const struct GNUNET_MessageHeader *message) { const struct SendMessageRequest *req; @@ -439,7 +441,8 @@ struct TokenizerContext * @param message the `struct SendMessage` */ static void -handle_client_send (void *cls, struct GNUNET_SERVER_Client *client, +handle_client_send (void *cls, + struct GNUNET_SERVER_Client *client, const struct GNUNET_MessageHeader *message) { const struct SendMessage *sm; @@ -699,8 +702,7 @@ GSC_CLIENTS_reject_request (struct GSC_ClientActiveRequest *car) */ void GSC_CLIENTS_notify_client_about_neighbour (struct GSC_Client *client, - const struct GNUNET_PeerIdentity - *neighbour, + const struct GNUNET_PeerIdentity *neighbour, const struct GSC_TypeMap *tmap_old, const struct GSC_TypeMap *tmap_new) { @@ -736,7 +738,8 @@ GSC_CLIENTS_notify_client_about_neighbour (struct GSC_Client *client, cnm->header.size = htons (size); cnm->header.type = htons (GNUNET_MESSAGE_TYPE_CORE_NOTIFY_CONNECT); cnm->reserved = htonl (0); - GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Sending `%s' message to client.\n", + GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, + "Sending `%s' message to client.\n", "NOTIFY_CONNECT"); cnm->peer = *neighbour; send_to_client (client, &cnm->header, GNUNET_NO); @@ -770,14 +773,13 @@ GSC_CLIENTS_notify_client_about_neighbour (struct GSC_Client *client, * @param tmap_new updated type map for the neighbour, NULL for disconnect */ void -GSC_CLIENTS_notify_clients_about_neighbour (const struct GNUNET_PeerIdentity - *neighbour, +GSC_CLIENTS_notify_clients_about_neighbour (const struct GNUNET_PeerIdentity *neighbour, const struct GSC_TypeMap *tmap_old, const struct GSC_TypeMap *tmap_new) { struct GSC_Client *c; - for (c = client_head; c != NULL; c = c->next) + for (c = client_head; NULL != c; c = c->next) GSC_CLIENTS_notify_client_about_neighbour (c, neighbour, tmap_old, tmap_new); } diff --git a/src/core/gnunet-service-core_kx.c b/src/core/gnunet-service-core_kx.c index 8f13dd111..38f37f01f 100644 --- a/src/core/gnunet-service-core_kx.c +++ b/src/core/gnunet-service-core_kx.c @@ -431,7 +431,8 @@ monitor_notify_all (struct GSC_KeyExchangeInfo *kx) */ static void derive_auth_key (struct GNUNET_CRYPTO_AuthKey *akey, - const struct GNUNET_CRYPTO_SymmetricSessionKey *skey, uint32_t seed) + const struct GNUNET_CRYPTO_SymmetricSessionKey *skey, + uint32_t seed) { static const char ctx[] = "authentication key"; @@ -1176,7 +1177,8 @@ GSC_KX_handle_pong (struct GSC_KeyExchangeInfo *kx, "PONG", GNUNET_i2s (&t.target), (unsigned int) t.challenge); return; } - GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Received PONG from `%s'\n", + GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, + "Received PONG from `%s'\n", GNUNET_i2s (&kx->peer)); /* no need to resend key any longer */ if (GNUNET_SCHEDULER_NO_TASK != kx->retry_set_key_task) diff --git a/src/core/gnunet-service-core_sessions.c b/src/core/gnunet-service-core_sessions.c index 79a609566..00db9d1f1 100644 --- a/src/core/gnunet-service-core_sessions.c +++ b/src/core/gnunet-service-core_sessions.c @@ -329,7 +329,8 @@ GSC_SESSIONS_create (const struct GNUNET_PeerIdentity *peer, GNUNET_CONTAINER_multipeermap_size (sessions), GNUNET_NO); GSC_CLIENTS_notify_clients_about_neighbour (peer, - NULL, session->tmap); + NULL, + session->tmap); start_typemap_task (session); } @@ -422,7 +423,8 @@ notify_client_about_session (void *cls, struct GSC_Client *client = cls; struct Session *session = value; - GSC_CLIENTS_notify_client_about_neighbour (client, &session->peer, + GSC_CLIENTS_notify_client_about_neighbour (client, + &session->peer, NULL, /* old TMAP: none */ session->tmap); return GNUNET_OK; diff --git a/src/core/gnunet-service-core_typemap.c b/src/core/gnunet-service-core_typemap.c index 13f5309fb..870b90085 100644 --- a/src/core/gnunet-service-core_typemap.c +++ b/src/core/gnunet-service-core_typemap.c @@ -247,8 +247,8 @@ GSC_TYPEMAP_add (const uint16_t *types, /** * Remove a set of types from our type map. * - * @param types array of message types no longer supported by this peer - * @param tlen number of entries in @a types + * @param types array of types to remove + * @param tlen length of the @a types array */ void GSC_TYPEMAP_remove (const uint16_t *types, -- cgit v1.2.3