gnunet-svn
[Top][All Lists]
Advanced

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

[libmicrohttpd] branch master updated (5ef86b74 -> 6621c055)


From: gnunet
Subject: [libmicrohttpd] branch master updated (5ef86b74 -> 6621c055)
Date: Tue, 24 Aug 2021 11:38:55 +0200

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

karlson2k pushed a change to branch master
in repository libmicrohttpd.

    from 5ef86b74 Stop deallocating memory buffer after each hunk or reply part
     new bacd53ec mhd_assert: ensure that either _DEBUG or NDEBUG is defined
     new 6621c055 mhd_assert: added check for both _DEBUG and NDEBUG defined

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/microhttpd/connection.c |  1 +
 src/microhttpd/mhd_assert.h | 12 +++++++++++-
 2 files changed, 12 insertions(+), 1 deletion(-)

diff --git a/src/microhttpd/connection.c b/src/microhttpd/connection.c
index 8ba793f4..c86dadf5 100644
--- a/src/microhttpd/connection.c
+++ b/src/microhttpd/connection.c
@@ -54,6 +54,7 @@
 #include <sys/param.h>
 #endif /* HAVE_SYS_PARAM_H */
 #include "mhd_send.h"
+#include "mhd_assert.h"
 
 /**
  * Message to transmit when http 1.1 request is received
diff --git a/src/microhttpd/mhd_assert.h b/src/microhttpd/mhd_assert.h
index e99632d0..6113646f 100644
--- a/src/microhttpd/mhd_assert.h
+++ b/src/microhttpd/mhd_assert.h
@@ -1,6 +1,6 @@
 /*
   This file is part of libmicrohttpd
-  Copyright (C) 2017 Karlson2k (Evgeny Grin)
+  Copyright (C) 2017-2021 Karlson2k (Evgeny Grin)
 
   This library is free software; you can redistribute it and/or
   modify it under the terms of the GNU Lesser General Public
@@ -23,10 +23,20 @@
  * @author Karlson2k (Evgeny Grin)
  */
 
+/* Unlike POSIX version of 'assert.h', MHD version of 'assert' header
+ * does not allow multiple redefinition of 'mhd_assert' macro within single
+ * souce file. */
 #ifndef MHD_ASSERT_H
 #define MHD_ASSERT_H 1
 
 #include "mhd_options.h"
+
+#if ! deifned(_DEBUG) && ! defined(NDEBUG)
+#define NDEBUG 1 /* Use NDEBUG by default */
+#endif /* !_DEBUG && !NDEBUG */
+#if deifned(_DEBUG) && defined(NDEBUG)
+#error Both _DEBUG and NDEBUG are defined
+#endif /* _DEBUG && NDEBUG */
 #ifdef NDEBUG
 #  define mhd_assert(ignore) ((void) 0)
 #else  /* _DEBUG */

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