[PATCH] C99 initializers for net/ipv6/netfilter

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

 



Hi.

Here are two patches for net/ipv6/netfilter that switch the files from
using the obsolete GCC array initializer syntax to C99 syntax. The
patches are against the BK kernel from January 15.

Art Haas

===== net/ipv6/netfilter/ip6table_filter.c 1.3 vs edited =====
--- 1.3/net/ipv6/netfilter/ip6table_filter.c	Tue Feb  5 09:24:40 2002
+++ edited/net/ipv6/netfilter/ip6table_filter.c	Thu Jan 16 10:55:25 2003
@@ -35,12 +35,12 @@
 } initial_table __initdata
 = { { "filter", FILTER_VALID_HOOKS, 4,
       sizeof(struct ip6t_standard) * 3 + sizeof(struct ip6t_error),
-      { [NF_IP6_LOCAL_IN] 0,
-	[NF_IP6_FORWARD] sizeof(struct ip6t_standard),
-	[NF_IP6_LOCAL_OUT] sizeof(struct ip6t_standard) * 2 },
-      { [NF_IP6_LOCAL_IN] 0,
-	[NF_IP6_FORWARD] sizeof(struct ip6t_standard),
-	[NF_IP6_LOCAL_OUT] sizeof(struct ip6t_standard) * 2 },
+      { [NF_IP6_LOCAL_IN] = 0,
+	[NF_IP6_FORWARD] = sizeof(struct ip6t_standard),
+	[NF_IP6_LOCAL_OUT] = sizeof(struct ip6t_standard) * 2 },
+      { [NF_IP6_LOCAL_IN] = 0,
+	[NF_IP6_FORWARD] = sizeof(struct ip6t_standard),
+	[NF_IP6_LOCAL_OUT] = sizeof(struct ip6t_standard) * 2 },
       0, NULL, { } },
     {
 	    /* LOCAL_IN */
===== net/ipv6/netfilter/ip6table_mangle.c 1.4 vs edited =====
--- 1.4/net/ipv6/netfilter/ip6table_mangle.c	Fri Oct 11 18:36:11 2002
+++ edited/net/ipv6/netfilter/ip6table_mangle.c	Thu Jan 16 10:56:10 2003
@@ -45,16 +45,16 @@
 } initial_table __initdata
 = { { "mangle", MANGLE_VALID_HOOKS, 6,
       sizeof(struct ip6t_standard) * 5 + sizeof(struct ip6t_error),
-      { [NF_IP6_PRE_ROUTING] 	0,
-	[NF_IP6_LOCAL_IN]	sizeof(struct ip6t_standard),
-	[NF_IP6_FORWARD]	sizeof(struct ip6t_standard) * 2,
-	[NF_IP6_LOCAL_OUT] 	sizeof(struct ip6t_standard) * 3,
-	[NF_IP6_POST_ROUTING]	sizeof(struct ip6t_standard) * 4},
-      { [NF_IP6_PRE_ROUTING] 	0,
-	[NF_IP6_LOCAL_IN]	sizeof(struct ip6t_standard),
-	[NF_IP6_FORWARD]	sizeof(struct ip6t_standard) * 2,
-	[NF_IP6_LOCAL_OUT] 	sizeof(struct ip6t_standard) * 3,
-	[NF_IP6_POST_ROUTING]	sizeof(struct ip6t_standard) * 4},
+      { [NF_IP6_PRE_ROUTING] 	= 0,
+	[NF_IP6_LOCAL_IN]	= sizeof(struct ip6t_standard),
+	[NF_IP6_FORWARD]	= sizeof(struct ip6t_standard) * 2,
+	[NF_IP6_LOCAL_OUT] 	= sizeof(struct ip6t_standard) * 3,
+	[NF_IP6_POST_ROUTING]	= sizeof(struct ip6t_standard) * 4},
+      { [NF_IP6_PRE_ROUTING] 	= 0,
+	[NF_IP6_LOCAL_IN]	= sizeof(struct ip6t_standard),
+	[NF_IP6_FORWARD]	= sizeof(struct ip6t_standard) * 2,
+	[NF_IP6_LOCAL_OUT] 	= sizeof(struct ip6t_standard) * 3,
+	[NF_IP6_POST_ROUTING]	= sizeof(struct ip6t_standard) * 4},
       0, NULL, { } },
     {
 	    /* PRE_ROUTING */
-- 
They that can give up essential liberty to obtain a little temporary safety
deserve neither liberty nor safety.
 -- Benjamin Franklin, Historical Review of Pennsylvania, 1759
-
: send the line "unsubscribe linux-net" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux 802.1Q VLAN]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Git]     [Bugtraq]     [Yosemite News and Information]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux PCI]     [Linux Admin]     [Samba]

  Powered by Linux