gnunet-svn
[Top][All Lists]
Advanced

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

[gnunet] branch master updated: -fix off-by-one on path truncation


From: gnunet
Subject: [gnunet] branch master updated: -fix off-by-one on path truncation
Date: Sat, 20 Aug 2022 14:41:27 +0200

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

grothoff pushed a commit to branch master
in repository gnunet.

The following commit(s) were added to refs/heads/master by this push:
     new 5882a3a56 -fix off-by-one on path truncation
5882a3a56 is described below

commit 5882a3a56708bf058e918166af9f2c4df66e2e29
Author: Christian Grothoff <christian@grothoff.org>
AuthorDate: Sat Aug 20 14:41:22 2022 +0200

    -fix off-by-one on path truncation
---
 src/dht/gnunet-service-dht_neighbours.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/dht/gnunet-service-dht_neighbours.c 
b/src/dht/gnunet-service-dht_neighbours.c
index 8611f2653..376ac5092 100644
--- a/src/dht/gnunet-service-dht_neighbours.c
+++ b/src/dht/gnunet-service-dht_neighbours.c
@@ -2083,7 +2083,7 @@ handle_dht_p2p_put (void *cls,
                     failure_offset);
         GNUNET_assert (failure_offset <= putlen + 1);
         bd.put_path = &pp[failure_offset];
-        bd.put_path_length = putlen - failure_offset;
+        bd.put_path_length = (putlen + 1) - failure_offset;
         bd.ro |= GNUNET_DHT_RO_TRUNCATED;
         bd.trunc_peer = pp[failure_offset - 1].pred;
       }

-- 
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]