typo in src/identity/gnunet-identity.c
[oweals/gnunet.git] / src / identity / identity_api.c
index 1a2b9e4da1f7011718f8969ab5ef2c09a770354a..1406ddd411e21bbeb445611981f9165e33fd49de 100644 (file)
@@ -1,6 +1,6 @@
 /*
      This file is part of GNUnet.
-     (C) 2013 Christian Grothoff (and other contributing authors)
+     Copyright (C) 2013 GNUnet e.V.
 
      GNUnet is free software; you can redistribute it and/or modify
      it under the terms of the GNU General Public Liceidentity as published
@@ -14,8 +14,8 @@
 
      You should have received a copy of the GNU General Public Liceidentity
      along with GNUnet; see the file COPYING.  If not, write to the
-     Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-     Boston, MA 02111-1307, USA.
+     Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+     Boston, MA 02110-1301, USA.
 */
 
 /**
@@ -87,19 +87,19 @@ struct GNUNET_IDENTITY_Operation
   const struct GNUNET_MessageHeader *msg;
 
   /**
-   * Continuation to invoke with the result of the transmission; 'cb'
+   * Continuation to invoke with the result of the transmission; @e cb
    * will be NULL in this case.
    */
   GNUNET_IDENTITY_Continuation cont;
 
   /**
    * Continuation to invoke with the result of the transmission for
-   * 'get' operations ('cont' will be NULL in this case).
+   * 'get' operations (@e cont will be NULL in this case).
    */
   GNUNET_IDENTITY_Callback cb;
 
   /**
-   * Closure for 'cont' or 'cb'.
+   * Closure for @e cont or @e cb.
    */
   void *cls;
 
@@ -155,7 +155,7 @@ struct GNUNET_IDENTITY_Handle
   /**
    * Task doing exponential back-off trying to reconnect.
    */
-  GNUNET_SCHEDULER_TaskIdentifier reconnect_task;
+  struct GNUNET_SCHEDULER_Task * reconnect_task;
 
   /**
    * Time for next connect retry.
@@ -195,11 +195,9 @@ GNUNET_IDENTITY_ego_get_anonymous ()
  * Try again to connect to the identity service.
  *
  * @param cls handle to the identity service.
- * @param tc scheduler context
  */
 static void
-reconnect (void *cls,
-          const struct GNUNET_SCHEDULER_TaskContext *tc);
+reconnect (void *cls);
 
 
 /**
@@ -210,7 +208,7 @@ reconnect (void *cls,
 static void
 reschedule_connect (struct GNUNET_IDENTITY_Handle *h)
 {
-  GNUNET_assert (h->reconnect_task == GNUNET_SCHEDULER_NO_TASK);
+  GNUNET_assert (h->reconnect_task == NULL);
 
   if (NULL != h->th)
   {
@@ -533,16 +531,15 @@ transmit_next (struct GNUNET_IDENTITY_Handle *h)
  * Try again to connect to the identity service.
  *
  * @param cls handle to the identity service.
- * @param tc scheduler context
  */
 static void
-reconnect (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc)
+reconnect (void *cls)
 {
   struct GNUNET_IDENTITY_Handle *h = cls;
   struct GNUNET_IDENTITY_Operation *op;
   struct GNUNET_MessageHeader msg;
 
-  h->reconnect_task = GNUNET_SCHEDULER_NO_TASK;
+  h->reconnect_task = NULL;
   LOG (GNUNET_ERROR_TYPE_DEBUG,
        "Connecting to identity service.\n");
   GNUNET_assert (NULL == h->client);
@@ -966,10 +963,10 @@ GNUNET_IDENTITY_disconnect (struct GNUNET_IDENTITY_Handle *h)
   struct GNUNET_IDENTITY_Operation *op;
 
   GNUNET_assert (NULL != h);
-  if (h->reconnect_task != GNUNET_SCHEDULER_NO_TASK)
+  if (h->reconnect_task != NULL)
   {
     GNUNET_SCHEDULER_cancel (h->reconnect_task);
-    h->reconnect_task = GNUNET_SCHEDULER_NO_TASK;
+    h->reconnect_task = NULL;
   }
   if (NULL != h->th)
   {