Skip to contentSkip to conversation

Missing limits.h includes

PATCH Applied Phil Oester 2 participants 2 messages Aug 19, 2008 – Sep 1, 2008 netfilter

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Missing limits.h includes

Latest git doesn't compile for me on Fedora 9 due to various *MAX constants being undefined. Below adds the include in 3 files which need it (although I can't see why this isn't required in 1.4.1.1).

Phil

extensions/libxt_esp.c +2 -0
diff -ruN ipt-orig/extensions/libxt_esp.c ipt-new/extensions/libxt_esp.c
@@ -5,6 +5,8 @@
 #include <stdlib.h>
 #include <getopt.h>
 #include <errno.h>
+#include <limits.h>
+
 #include <xtables.h>
 #include <linux/netfilter/xt_esp.h>
 
extensions/libxt_owner.c +1 -0
diff -ruN ipt-orig/extensions/libxt_owner.c ipt-new/extensions/libxt_owner.c
@@ -12,6 +12,7 @@
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
+#include <limits.h>
 
 #include <xtables.h>
 #include <linux/netfilter/xt_owner.h>
extensions/libxt_time.c +2 -0
diff -ruN ipt-orig/extensions/libxt_time.c ipt-new/extensions/libxt_time.c
@@ -18,6 +18,8 @@
 #include <stdlib.h>
 #include <stddef.h>
 #include <time.h>
+#include <limits.h>
+
 #include <linux/netfilter/xt_time.h>
 #include <xtables.h>
 #define ARRAY_SIZE(x) (sizeof(x) / sizeof(*x))
#1 lore raw
Quoted 3 lines · Phil Oester

Latest git doesn't compile for me on Fedora 9 due to various *MAX constants being undefined. Below adds the include in 3 files which need it (although I can't see why this isn't required in 1.4.1.1).

Applied, thanks.