gnunet-svn
[Top][All Lists]
Advanced

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

[gnunet] branch master updated (bef6c0a6a -> 1a82df7c1)


From: gnunet
Subject: [gnunet] branch master updated (bef6c0a6a -> 1a82df7c1)
Date: Tue, 09 Jan 2024 19:16:53 +0100

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

grothoff pushed a change to branch master
in repository gnunet.

    from bef6c0a6a fix #8044
     new 4295f445e fix #8042
     new 1a82df7c1 fix #8043

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 src/lib/json/json_generator.c | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/src/lib/json/json_generator.c b/src/lib/json/json_generator.c
index 4fda86e32..43b72ba57 100644
--- a/src/lib/json/json_generator.c
+++ b/src/lib/json/json_generator.c
@@ -34,8 +34,7 @@ GNUNET_JSON_from_data (const void *data,
   char *buf;
   json_t *json;
 
-  if ((size * 8 + 4) / 5 + 1 >=
-      GNUNET_MAX_MALLOC_CHECKED)
+  if (size >= ( (GNUNET_MAX_MALLOC_CHECKED - 1) * 5) - 4 / 8)
   {
     GNUNET_break (0);
     return NULL;
@@ -57,8 +56,7 @@ GNUNET_JSON_from_data64 (const void *data,
   json_t *json;
   size_t len;
 
-  if ((size * 8 + 5) / 6 + 1 >=
-      GNUNET_MAX_MALLOC_CHECKED)
+  if (size >= ( ( (GNUNET_MAX_MALLOC_CHECKED - 1) * 6) - 5) / 8)
   {
     GNUNET_break (0);
     return NULL;

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