gnunet-svn
[Top][All Lists]
Advanced

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

[gnunet] 15/18: TNG: Fixed bug that additional queues for the same commu


From: gnunet
Subject: [gnunet] 15/18: TNG: Fixed bug that additional queues for the same communicator inherit the validity period.
Date: Tue, 02 May 2023 12:53:30 +0200

This is an automated email from the git hooks/post-receive script.

t3sserakt pushed a commit to branch master
in repository gnunet.

commit e0d5206115db8eeeb42ca50237805f165f60c954
Author: t3sserakt <t3ss@posteo.de>
AuthorDate: Thu Apr 27 18:11:46 2023 +0200

    TNG: Fixed bug that additional queues for the same communicator inherit the 
validity period.
---
 src/transport/gnunet-service-tng.c | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/src/transport/gnunet-service-tng.c 
b/src/transport/gnunet-service-tng.c
index c30d2dd19..f030944bb 100644
--- a/src/transport/gnunet-service-tng.c
+++ b/src/transport/gnunet-service-tng.c
@@ -10899,6 +10899,7 @@ handle_add_queue_message (void *cls,
   struct TransportClient *tc = cls;
   struct Queue *queue;
   struct Neighbour *neighbour;
+  struct GNUNET_TIME_Absolute validated_until = GNUNET_TIME_UNIT_ZERO_ABS;
   const char *addr;
   uint16_t addr_len;
 
@@ -10915,6 +10916,7 @@ handle_add_queue_message (void *cls,
        NULL != queue;
        queue = queue->next_client)
   {
+    validated_until = queue->validated_until;
     if (queue->qid != ntohl (aqm->qid))
       continue;
     break;
@@ -10956,6 +10958,13 @@ handle_add_queue_message (void *cls,
                 ntohl (aqm->mtu));
     queue = GNUNET_malloc (sizeof(struct Queue) + addr_len);
     queue->tc = tc;
+    if (GNUNET_TIME_UNIT_ZERO_ABS.abs_value_us != validated_until.abs_value_us)
+    {
+      GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
+                  "New queue with QID %lu inherit validated until\n",
+                  ntohl (aqm->qid));
+      queue->validated_until = validated_until;
+    }
     queue->address = (const char *) &queue[1];
     queue->pd.aged_rtt = GNUNET_TIME_UNIT_FOREVER_REL;
     queue->qid = ntohl (aqm->qid);

-- 
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.



reply via email to

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