]> git.ipfire.org Git - thirdparty/iptables.git/commitdiff
extensions: Add macro _DEFAULT_SOURCE.
authorVarsha Rao <rvarsha016@gmail.com>
Thu, 21 Dec 2017 03:35:45 +0000 (09:05 +0530)
committerPablo Neira Ayuso <pablo@netfilter.org>
Thu, 21 Dec 2017 08:12:33 +0000 (09:12 +0100)
Define _DEFAULT_SOURCE as _BSD_SOURCE is deprecated.
https://sourceware.org/glibc/wiki/Release/2.20#Packaging_Changes

This patch fixes the following warning:

warning: #warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use
_DEFAULT_SOURCE" [-Wcpp]
 # warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use
 # _DEFAULT_SOURCE"

Signed-off-by: Varsha Rao <rvarsha016@gmail.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
extensions/libxt_hashlimit.c
extensions/libxt_limit.c

index e51ac1aea94b3355592a9579369c6505fa5c9602..ffe342a7c86cbc381cc9236b571675e1c2a21056 100644 (file)
@@ -11,6 +11,7 @@
  * Error corections by nmalykh@bilim.com (22.01.2005)
  */
 #define _BSD_SOURCE 1
+#define _DEFAULT_SOURCE 1
 #define _ISOC99_SOURCE 1
 #include <inttypes.h>
 #include <math.h>
index 5cc95c2ebcaf8cc895e8896d9a79cdc89ea5e9a1..c8ddca8778400991868f6100382215e24e67a459 100644 (file)
@@ -4,6 +4,7 @@
  * HervĂ© Eychenne    <rv@wallfire.org>
  */
 #define _BSD_SOURCE 1
+#define _DEFAULT_SOURCE 1
 #define _ISOC99_SOURCE 1
 #include <math.h>
 #include <stdio.h>