]> git.ipfire.org Git - thirdparty/unbound.git/commitdiff
- Fix to guard _OPENBSD_SOURCE from redefinition.
authorW.C.A. Wijngaards <wouter@nlnetlabs.nl>
Wed, 29 May 2019 11:28:03 +0000 (13:28 +0200)
committerW.C.A. Wijngaards <wouter@nlnetlabs.nl>
Wed, 29 May 2019 11:28:03 +0000 (13:28 +0200)
config.h.in
configure
configure.ac
doc/Changelog

index e8795c7ef158cdea188b327b57388ce3bfa27793..e2d3116cccf065b932b452c2e0ce5217b61d02b4 100644 (file)
 
 
 
+#ifndef _OPENBSD_SOURCE
+#define _OPENBSD_SOURCE 1
+#endif
+
 #ifndef UNBOUND_DEBUG
 # ifndef NDEBUG
 #  define NDEBUG
index 6a83da1642bbc2231f93af9d248322a2549cad96..21721689dc3a971a3811a51c4af4fd24dbf7e5a8 100755 (executable)
--- a/configure
+++ b/configure
@@ -20150,7 +20150,9 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 $ac_includes_default
 
+#ifndef _OPENBSD_SOURCE
 #define _OPENBSD_SOURCE 1
+#endif
 #include <stdlib.h>
 int main(void) {
        void* p = reallocarray(NULL, 10, 100);
index 05acbe8a08f09dc206d84445c9c55b4a74b4bf7f..fc9448f51a09bb9e78d7457510a5df5ca8de2683 100644 (file)
@@ -1450,7 +1450,9 @@ AC_SUBST(LIBOBJ_WITHOUT_CTIMEARC4)
 AC_MSG_CHECKING([for reallocarray])
 AC_LINK_IFELSE([AC_LANG_SOURCE(AC_INCLUDES_DEFAULT
 [[
+#ifndef _OPENBSD_SOURCE
 #define _OPENBSD_SOURCE 1
+#endif
 #include <stdlib.h>
 int main(void) {
        void* p = reallocarray(NULL, 10, 100);
@@ -1675,6 +1677,10 @@ AHX_CONFIG_EXT_FLAGS
 
 dnl includes
 [
+#ifndef _OPENBSD_SOURCE
+#define _OPENBSD_SOURCE 1
+#endif
+
 #ifndef UNBOUND_DEBUG
 # ifndef NDEBUG
 #  define NDEBUG
index 3c9e956feb1cbf9c41fcf592a986c0a668f73ed0..7c521044b9cc488774da2a3655da8928300fa8b8 100644 (file)
@@ -1,3 +1,6 @@
+29 May 2019: Wouter
+       - Fix to guard _OPENBSD_SOURCE from redefinition.
+
 28 May 2019: Wouter
        - Fix to define _OPENBSD_SOURCE to get reallocarray on NetBSD.
        - gitignore config.h.in~.