gnunet-svn
[Top][All Lists]
Advanced

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

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


From: gnunet
Subject: [GNUnet-SVN] r28258 - gnunet/src/mesh
Date: Tue, 23 Jul 2013 01:31:16 +0200

Author: bartpolot
Date: 2013-07-23 01:31:16 +0200 (Tue, 23 Jul 2013)
New Revision: 28258

Modified:
   gnunet/src/mesh/gnunet-service-mesh.c
Log:
- send ack could call queue_add and set the handler

Modified: gnunet/src/mesh/gnunet-service-mesh.c
===================================================================
--- gnunet/src/mesh/gnunet-service-mesh.c       2013-07-22 23:20:26 UTC (rev 
28257)
+++ gnunet/src/mesh/gnunet-service-mesh.c       2013-07-22 23:31:16 UTC (rev 
28258)
@@ -3611,7 +3611,7 @@
 
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "* Queue send\n");
 
-  if (NULL == buf || 0 ==size)
+  if (NULL == buf || 0 == size)
   {
     GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "* Buffer size 0.\n");
     return 0;
@@ -3733,19 +3733,23 @@
   queue = queue_get_next (peer);
   if (NULL != queue)
   {
-      struct GNUNET_PeerIdentity id;
-
       GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "*   more data!\n");
-      GNUNET_PEER_resolve (peer->id, &id);
-      peer->core_transmit =
-          GNUNET_CORE_notify_transmit_ready(core_handle,
-                                            0,
-                                            0,
-                                            GNUNET_TIME_UNIT_FOREVER_REL,
-                                            &id,
-                                            queue->size,
-                                            &queue_send,
-                                            peer);
+      if (NULL == peer->core_transmit) {
+        peer->core_transmit =
+            GNUNET_CORE_notify_transmit_ready(core_handle,
+                                              0,
+                                              0,
+                                              GNUNET_TIME_UNIT_FOREVER_REL,
+                                              &dst_id,
+                                              queue->size,
+                                              &queue_send,
+                                              peer);
+      }
+      else
+      {
+        GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
+                    "*   tmt rdy called somewhere else\n");
+      }
   }
   if (peer->id == t->next_hop)
     fc = &t->next_fc;




reply via email to

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