gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GNUnet-SVN] r27084 - gnunet/src/mesh


From: gnunet
Subject: [GNUnet-SVN] r27084 - gnunet/src/mesh
Date: Fri, 10 May 2013 10:15:37 +0200

Author: bartpolot
Date: 2013-05-10 10:15:37 +0200 (Fri, 10 May 2013)
New Revision: 27084

Modified:
   gnunet/src/mesh/gnunet-service-mesh-new.c
Log:
- clean up

Modified: gnunet/src/mesh/gnunet-service-mesh-new.c
===================================================================
--- gnunet/src/mesh/gnunet-service-mesh-new.c   2013-05-10 08:04:29 UTC (rev 
27083)
+++ gnunet/src/mesh/gnunet-service-mesh-new.c   2013-05-10 08:15:37 UTC (rev 
27084)
@@ -2633,7 +2633,6 @@
   switch (type)
   {
     case GNUNET_MESSAGE_TYPE_MESH_UNICAST:
-    case GNUNET_MESSAGE_TYPE_MESH_MULTICAST:
       GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
                   "ACK due to FWD DATA retransmission\n");
       if (GNUNET_YES == t->nobuffer)
@@ -2963,8 +2962,7 @@
     next = pq->next;
     if (pq->tunnel == t)
     {
-      if (GNUNET_MESSAGE_TYPE_MESH_MULTICAST == pq->type ||
-          GNUNET_MESSAGE_TYPE_MESH_UNICAST == pq->type ||
+      if (GNUNET_MESSAGE_TYPE_MESH_UNICAST == pq->type ||
           GNUNET_MESSAGE_TYPE_MESH_TO_ORIGIN == pq->type)
       {
         // Should have been removed on destroy children
@@ -3814,8 +3812,7 @@
   unsigned int *n;
 
   n = NULL;
-  if (GNUNET_MESSAGE_TYPE_MESH_UNICAST == type ||
-      GNUNET_MESSAGE_TYPE_MESH_MULTICAST == type)
+  if (GNUNET_MESSAGE_TYPE_MESH_UNICAST == type)
   {
     n = &t->fwd_queue_n;
     max = &t->fwd_queue_max;
@@ -5004,9 +5001,9 @@
 /**
  * Handler for requests of new tunnels
  *
- * @param cls closure
- * @param client identification of the client
- * @param message the actual message
+ * @param cls Closure.
+ * @param client Identification of the client.
+ * @param message The actual message.
  */
 static void
 handle_local_tunnel_create (void *cls, struct GNUNET_SERVER_Client *client,
@@ -5058,17 +5055,16 @@
 
   while (NULL != tunnel_get_by_pi (myid, next_tid))
     next_tid = (next_tid + 1) & ~GNUNET_MESH_LOCAL_TUNNEL_ID_CLI;
-  t = tunnel_new (myid, next_tid++, c, tid);
+  t = tunnel_new (myid, next_tid, c, tid);
+  next_tid = (next_tid + 1) & ~GNUNET_MESH_LOCAL_TUNNEL_ID_CLI;
   if (NULL == t)
   {
     GNUNET_break (0);
     GNUNET_SERVER_receive_done (client, GNUNET_SYSERR);
     return;
   }
-  next_tid = next_tid & ~GNUNET_MESH_LOCAL_TUNNEL_ID_CLI;
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "CREATED TUNNEL %s [%x] (%x)\n",
               GNUNET_i2s (&my_full_id), t->id.tid, t->local_tid);
-  GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "new tunnel created\n");
 
   peer_info = peer_get (&t_msg->peer);
   GNUNET_array_append (peer_info->tunnels, peer_info->ntunnels, t);




reply via email to

[Prev in Thread] Current Thread [Next in Thread]