gnunet-svn
[Top][All Lists]
Advanced

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

[GNUnet-SVN] r35645 - gnunet/src/cadet


From: gnunet
Subject: [GNUnet-SVN] r35645 - gnunet/src/cadet
Date: Mon, 27 Apr 2015 21:15:48 +0200

Author: bartpolot
Date: 2015-04-27 21:15:48 +0200 (Mon, 27 Apr 2015)
New Revision: 35645

Modified:
   gnunet/src/cadet/gnunet-service-cadet_connection.c
Log:
- don't ttl drop ax

Modified: gnunet/src/cadet/gnunet-service-cadet_connection.c
===================================================================
--- gnunet/src/cadet/gnunet-service-cadet_connection.c  2015-04-27 19:15:47 UTC 
(rev 35644)
+++ gnunet/src/cadet/gnunet-service-cadet_connection.c  2015-04-27 19:15:48 UTC 
(rev 35645)
@@ -2297,14 +2297,17 @@
 
   /* Message not for us: forward to next hop */
   LOG (GNUNET_ERROR_TYPE_DEBUG, "  not for us, retransmitting...\n");
-  ttl = ntohl (msg->ttl);
-  LOG (GNUNET_ERROR_TYPE_DEBUG, "   ttl: %u\n", ttl);
-  if (ttl == 0)
+  if (NULL != otr_msg) /* only otr has ttl */
   {
-    GNUNET_STATISTICS_update (stats, "# TTL drops", 1, GNUNET_NO);
-    LOG (GNUNET_ERROR_TYPE_WARNING, " TTL is 0, DROPPING!\n");
-    GCC_send_ack (c, fwd, GNUNET_NO);
-    return GNUNET_OK;
+    ttl = ntohl (otr_msg->ttl);
+    LOG (GNUNET_ERROR_TYPE_DEBUG, "   ttl: %u\n", ttl);
+    if (ttl == 0)
+    {
+      GNUNET_STATISTICS_update (stats, "# TTL drops", 1, GNUNET_NO);
+      LOG (GNUNET_ERROR_TYPE_WARNING, " TTL is 0, DROPPING!\n");
+      GCC_send_ack (c, fwd, GNUNET_NO);
+      return GNUNET_OK;
+    }
   }
 
   GNUNET_STATISTICS_update (stats, "# messages forwarded", 1, GNUNET_NO);




reply via email to

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