]> git.ipfire.org Git - thirdparty/iptables.git/commitdiff
Make the option structures const.
authorJan Engelhardt <jengelh@medozas.de>
Mon, 30 Jul 2007 14:46:51 +0000 (14:46 +0000)
committerYasuyuki KOZAKAI <yasuyuki@netfilter.org>
Mon, 30 Jul 2007 14:46:51 +0000 (14:46 +0000)
Signed-off-by: Jan Engelhardt <jengelh@gmx.de>
84 files changed:
extensions/libip6t_CONNMARK.c
extensions/libip6t_CONNSECMARK.c
extensions/libip6t_HL.c
extensions/libip6t_LOG.c
extensions/libip6t_MARK.c
extensions/libip6t_NFLOG.c
extensions/libip6t_REJECT.c
extensions/libip6t_ah.c
extensions/libip6t_condition.c
extensions/libip6t_connmark.c
extensions/libip6t_dst.c
extensions/libip6t_frag.c
extensions/libip6t_hashlimit.c
extensions/libip6t_hbh.c
extensions/libip6t_hl.c
extensions/libip6t_icmp6.c
extensions/libip6t_ipv6header.c
extensions/libip6t_mh.c
extensions/libip6t_owner.c
extensions/libip6t_policy.c
extensions/libip6t_rt.c
extensions/libip6t_state.c
extensions/libipt_CLASSIFY.c
extensions/libipt_CLUSTERIP.c
extensions/libipt_CONNMARK.c
extensions/libipt_CONNSECMARK.c
extensions/libipt_DNAT.c
extensions/libipt_DSCP.c
extensions/libipt_ECN.c
extensions/libipt_LOG.c
extensions/libipt_MARK.c
extensions/libipt_MASQUERADE.c
extensions/libipt_NETMAP.c
extensions/libipt_NFLOG.c
extensions/libipt_REDIRECT.c
extensions/libipt_REJECT.c
extensions/libipt_SAME.c
extensions/libipt_SET.c
extensions/libipt_SNAT.c
extensions/libipt_TOS.c
extensions/libipt_TTL.c
extensions/libipt_ULOG.c
extensions/libipt_addrtype.c
extensions/libipt_ah.c
extensions/libipt_condition.c
extensions/libipt_connbytes.c
extensions/libipt_connmark.c
extensions/libipt_connrate.c
extensions/libipt_conntrack.c
extensions/libipt_dscp_helper.c
extensions/libipt_ecn.c
extensions/libipt_hashlimit.c
extensions/libipt_helper.c
extensions/libipt_icmp.c
extensions/libipt_iprange.c
extensions/libipt_owner.c
extensions/libipt_policy.c
extensions/libipt_realm.c
extensions/libipt_recent.c
extensions/libipt_set.c
extensions/libipt_state.c
extensions/libipt_statistic.c
extensions/libipt_tos.c
extensions/libipt_ttl.c
extensions/libxt_NFQUEUE.c
extensions/libxt_SECMARK.c
extensions/libxt_TCPMSS.c
extensions/libxt_comment.c
extensions/libxt_dccp.c
extensions/libxt_dscp.c
extensions/libxt_esp.c
extensions/libxt_length.c
extensions/libxt_limit.c
extensions/libxt_mac.c
extensions/libxt_mark.c
extensions/libxt_multiport.c
extensions/libxt_physdev.c
extensions/libxt_pkttype.c
extensions/libxt_quota.c
extensions/libxt_sctp.c
extensions/libxt_string.c
extensions/libxt_tcp.c
extensions/libxt_tcpmss.c
extensions/libxt_udp.c

index 69d3a5aa199cdce5d9e2bfa5ce39a229fc3711f8..03441d737a3a31447c316a0e1990cf5a86c36694 100644 (file)
@@ -48,7 +48,7 @@ help(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "set-mark", 1, 0, '1' },
        { "save-mark", 0, 0, '2' },
        { "restore-mark", 0, 0, '3' },
index 805492c5d2547fd8380022a0842e14a1f60716a6..93d0c966682098eb5f3f6f3e4223fa5f8f6a6f1d 100644 (file)
@@ -24,7 +24,7 @@ static void help(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "save", 0, 0, '1' },
        { "restore", 0, 0, '2' },
        { 0 }
index 33bab71492e19b61f2039c9052e1edfc88213ac0..d215eaa50b5c5b8d6d576ec4eb9dff38f4ad1821 100644 (file)
@@ -138,7 +138,7 @@ static void print(const void *ip,
        printf("%u ", info->hop_limit);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "hl-set", 1, 0, '1' },
        { "hl-dec", 1, 0, '2' },
        { "hl-inc", 1, 0, '3' },
index 7fdbc0c83dcd6604d98fe7f353b2ce5a2906fa61..a11b8c01af614b092d750e7808e2d133d6cbb778 100644 (file)
@@ -32,7 +32,7 @@ help(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { .name = "log-level",        .has_arg = 1, .flag = 0, .val = '!' },
        { .name = "log-prefix",       .has_arg = 1, .flag = 0, .val = '#' },
        { .name = "log-tcp-sequence", .has_arg = 0, .flag = 0, .val = '1' },
index 0ca405954bd6ff1599607dfb42a91bbe77673fd9..19bf40d22725b11f1bd59bed8511c4667af7d842 100644 (file)
@@ -20,7 +20,7 @@ help(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { .name = "set-mark", .has_arg = 1, .flag = 0, .val = '1' },
        { .name = 0 }
 };
index 22c99e90480ac64af587052703d68e8e78a8508b..42e2081971c35e89ca4b579f57c0355a5ad3e0ae 100644 (file)
@@ -14,7 +14,7 @@ enum {
        NFLOG_THRESHOLD = 0x8,
 };
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "nflog-group",     1, 0, NFLOG_GROUP },
        { "nflog-prefix",    1, 0, NFLOG_PREFIX },
        { "nflog-range",     1, 0, NFLOG_RANGE },
index ffc9680e72caa613959044fea0a6d082d0bd2c05..c67de0eb4428ab24a57294255c38a03d232d4e89 100644 (file)
@@ -65,7 +65,7 @@ help(void)
        print_reject_types();
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "reject-with", 1, 0, '1' },
        { 0 }
 };
index 2379f21abd7f19686c96a721b9f509d0692f4eb0..d3048a264d216a4c2e6fbb6cadbb813fd4c22af7 100644 (file)
@@ -20,7 +20,7 @@ help(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { .name = "ahspi", .has_arg = 1, .flag = 0, .val = '1' },
        { .name = "ahlen", .has_arg = 1, .flag = 0, .val = '2' },
        { .name = "ahres", .has_arg = 0, .flag = 0, .val = '3' },
index 633eef19bfbebb3f35de8ad10d9e5a6aa34093ce..40d05225ac72e6b2ecc3438622768f83c18d702c 100644 (file)
@@ -19,7 +19,7 @@ help(void)
 }
 
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { .name = "condition", .has_arg = 1, .flag = 0, .val = 'X' },
        { .name = 0 }
 };
index 0a67c3a2b5ed581783e5870343c7d57d17ac92b0..427003a3606f8a4a8d9e36ed5b43034e0125324e 100644 (file)
@@ -39,7 +39,7 @@ help(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "mark", 1, 0, '1' },
        {0}
 };
index 8c9455b1f56921071b2b5cf4043fbdfd31777d0f..cb49c1fbc0dfdf3326755d4c68cdfa8a835db494 100644 (file)
@@ -31,7 +31,7 @@ UNAME " v%s options:\n"
 IPTABLES_VERSION, IP6T_OPTS_OPTSNR);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { .name = LNAME "-len",        .has_arg = 1, .flag = 0, .val = '1' },
        { .name = LNAME "-opts",       .has_arg = 1, .flag = 0, .val = '2' },
        { .name = LNAME "-not-strict", .has_arg = 1, .flag = 0, .val = '3' },
index fcdee1b6c8754725e1631d5e32f4c209affc6204..1e184b73cddc7127a02ead47c27025d7b0368f2a 100644 (file)
@@ -23,7 +23,7 @@ help(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { .name = "fragid",    .has_arg = 1, .flag = 0, .val = '1' },
        { .name = "fraglen",   .has_arg = 1, .flag = 0, .val = '2' },
        { .name = "fragres",   .has_arg = 0, .flag = 0, .val = '3' },
index 9f820fc831b0832d73c7846bdddab1caf9e2e878..22cca0be648b511f500a71e120646f0aef7530b5 100644 (file)
@@ -46,7 +46,7 @@ help(void)
 "\n", IPTABLES_VERSION, XT_HASHLIMIT_BURST);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "hashlimit", 1, 0, '%' },
        { "hashlimit-burst", 1, 0, '$' },
        { "hashlimit-htable-size", 1, 0, '&' },
index 4312399ebca16c20dbc49092a580de15798b4185..c139c2337a7451fa2cfd48fffe3701b8579e112b 100644 (file)
@@ -30,14 +30,14 @@ UNAME , IPTABLES_VERSION, LNAME, LNAME, IP6T_OPTS_OPTSNR);
 }
 
 #if HOPBYHOP
-static struct option opts[] = {
+static const struct option opts[] = {
        { "hbh-len", 1, 0, '1' },
        { "hbh-opts", 1, 0, '2' },
        { "hbh-not-strict", 1, 0, '3' },
        {0}
 };
 #else
-static struct option opts[] = {
+static const struct option opts[] = {
        { "dst-len", 1, 0, '1' },
        { "dst-opts", 1, 0, '2' },
        { "dst-not-strict", 1, 0, '3' },
index 58b9fcfd93d612ca1a3cf088002dab1b826a30e2..197ef853d31cb5cb53eb598f6524147e4efaee96 100644 (file)
@@ -120,7 +120,7 @@ static void save(const void *ip,
        printf("--hl-%s %u ", op[info->mode], info->hop_limit);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { .name = "hl",    .has_arg = 1, .flag = 0, .val = '2' },
        { .name = "hl-eq", .has_arg = 1, .flag = 0, .val = '2' },
        { .name = "hl-lt", .has_arg = 1, .flag = 0, .val = '3' },
index bc150c28c84c07a6483529df73a3bdf33007a031..46c9d38d368a36f9ba647af0cafa8e766f9d2f66 100644 (file)
@@ -85,7 +85,7 @@ help(void)
        print_icmpv6types();
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "icmpv6-type", 1, 0, '1' },
        {0}
 };
index 858e0293e9718ea8f97e42c67b6f123d5b326a91..4dab33fcbcee966b13d898a7f141bc20a778ca1a 100644 (file)
@@ -148,7 +148,7 @@ help(void)
        IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "header", 1, 0, '1' },
        { "soft", 0, 0, '2' },
        { 0 }
index 3ae1cd44e68cbdd76eea9972f7ced35af55ba4b9..d2f9cec917efdceaaf36577d0753b765bc9c339c 100644 (file)
@@ -226,7 +226,7 @@ static void save(const void *ip, const struct xt_entry_match *match)
                printf("--mh-type %u ", mhinfo->types[0]);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "mh-type", 1, 0, '1' },
        {0}
 };
index ff671ab2f548e4e5e14d9d92fc51715250b7eee2..a5ec8da581af8813c010a66d76d5962411c04539 100644 (file)
@@ -36,7 +36,7 @@ IPTABLES_VERSION);
 #endif /* IP6T_OWNER_COMM */
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "uid-owner", 1, 0, '1' },
        { "gid-owner", 1, 0, '2' },
        { "pid-owner", 1, 0, '3' },
index b7062c62936248cc5ee0bc3134e2129e84d6fabe..4612e141e37b6a158bc747ed9f3b4fea2d2030a5 100644 (file)
@@ -41,7 +41,7 @@ static void help(void)
        IPTABLES_VERSION);
 }
 
-static struct option opts[] =
+static const struct option opts[] =
 {
        {
                .name           = "dir",
index a36c65aeb666030f9fbc2e5f26acfefe226bbde1..3c3911e3fb3f017b7f8e137c6d7fa062cb0916d1 100644 (file)
@@ -29,7 +29,7 @@ help(void)
 IPTABLES_VERSION, IP6T_RT_HOPS);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "rt-type", 1, 0, '1' },
        { "rt-segsleft", 1, 0, '2' },
        { "rt-len", 1, 0, '3' },
index b7c251721969f16b20e2aa8e26c789945856f59e..d7fc83c7f18864f9e9915221e4911b7888b1170c 100644 (file)
@@ -23,7 +23,7 @@ help(void)
 "\n", IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "state", 1, 0, '1' },
        {0}
 };
index 044ea9594e716693a074211aee93c170cc64138f..3096edc8e56c095e8456189f09181014aa35b6d2 100644 (file)
@@ -21,7 +21,7 @@ help(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "set-class", 1, 0, '1' },
        { 0 }
 };
index 30ae3bfccb38610bb007a5d535e8e1fba79e35d8..aa2ad2c78f33f7f1bc4ba15c337414d793d08a49 100644 (file)
@@ -44,7 +44,7 @@ IPTABLES_VERSION);
 #define PARAM_LOCALNODE        0x0010
 #define PARAM_HASHINIT 0x0020
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "new", 0, 0, '1' },
        { "hashmode", 1, 0, '2' },
        { "clustermac", 1, 0, '3' },
index fbf0d4d06e392738fad9a8343ef35ca70dd0c5af..2797b1bc1d4d0f6ea6fe59676a65202987dc4aac 100644 (file)
@@ -48,7 +48,7 @@ help(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "set-mark", 1, 0, '1' },
        { "save-mark", 0, 0, '2' },
        { "restore-mark", 0, 0, '3' },
index 191cd9adce952a86c5a88ec05257cc8ecc4dc9ee..07b8527b91c217aee2d7edafdedbc19467d96f3d 100644 (file)
@@ -24,7 +24,7 @@ static void help(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "save", 0, 0, '1' },
        { "restore", 0, 0, '2' },
        { 0 }
index 0d787637b802dbb2f80da809116cd1e5765f99ec..9f48e9c503f39a8c2917c2c9a37bf5f62f37871e 100644 (file)
@@ -32,7 +32,7 @@ help(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "to-destination", 1, 0, '1' },
        { "random", 0, 0, '2' },
        { 0 }
index b1a0df0f6a14ad341c6e8fdcc5fe224eb8c50745..029c54fe27b269cd48d23696ed633cfeaf04c76a 100644 (file)
@@ -42,7 +42,7 @@ static void help(void)
 );
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "set-dscp", 1, 0, 'F' },
        { "set-dscp-class", 1, 0, 'G' },
        { 0 }
index 7c6c29397c96734fb39dadfbea9db4390ae20f9b..314531e38a6b9f776ba2a50f44b0f389562e5f32 100644 (file)
@@ -37,7 +37,7 @@ static void help(void)
 #endif
 
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "ecn-tcp-remove", 0, 0, 'F' },
        { "ecn-tcp-cwr", 1, 0, 'G' },
        { "ecn-tcp-ece", 1, 0, 'H' },
index dca1edf270240c25652329220b5f1fbc24029716..4be14d5c079795e21b8fc468b081b1a5c7f34c97 100644 (file)
@@ -32,7 +32,7 @@ help(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { .name = "log-level",        .has_arg = 1, .flag = 0, .val = '!' },
        { .name = "log-prefix",       .has_arg = 1, .flag = 0, .val = '#' },
        { .name = "log-tcp-sequence", .has_arg = 0, .flag = 0, .val = '1' },
index 6a9471821d9c5ecf0a04e4b1a3ddf32237c6e05f..6c96656692d62df50caa631ab2d17d42c0748544 100644 (file)
@@ -22,7 +22,7 @@ help(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "set-mark", 1, 0, '1' },
        { "and-mark", 1, 0, '2' },
        { "or-mark", 1, 0, '3' },
index 0a94939123fd0dee311c55669d8e99f9d45912e3..07e93b3857c0cf055645f1a06c164cced22fa76d 100644 (file)
@@ -23,7 +23,7 @@ help(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "to-ports", 1, 0, '1' },
        { "random", 0, 0, '2' },
        { 0 }
index 302448f6764512a0121c2370039f8e39619b133f..ef06e01c19ebc5a567002e90d1d9baec79b25847 100644 (file)
@@ -13,7 +13,7 @@
 
 #define MODULENAME "NETMAP"
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "to", 1, 0, '1' },
        { 0 }
 };
index 37df5b0db7a3fe78ee12b72450bd27b6bbf215e8..a672e2d33768c88f08b389bfb7a81db3c4c1ac96 100644 (file)
@@ -14,7 +14,7 @@ enum {
        NFLOG_THRESHOLD = 0x8,
 };
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "nflog-group",     1, 0, NFLOG_GROUP },
        { "nflog-prefix",    1, 0, NFLOG_PREFIX },
        { "nflog-range",     1, 0, NFLOG_RANGE },
index 0aff8be86415e634e333826da894af755c4447ef..919fde578b8cae327adbeb4257597d43d695ba1d 100644 (file)
@@ -22,7 +22,7 @@ help(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "to-ports", 1, 0, '1' },
        { "random", 1, 0, '2' },
        { 0 }
index 4e083f39dafe15c1f98792100a906d11755ab184..8aba561ecf0003243a07331c0d2a94c0fbabdc4e 100644 (file)
@@ -80,7 +80,7 @@ help(void)
        printf("(*) See man page or read the INCOMPATIBILITES file for compatibility issues.\n");
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "reject-with", 1, 0, '1' },
        { 0 }
 };
index b14c50168817989ec60de40b8509480375f87730..fe4df9928f10e0681ca918528d153a159792390e 100644 (file)
@@ -29,7 +29,7 @@ help(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "to", 1, 0, '1' },
        { "nodst", 0, 0, '2'},
        { "random", 0, 0, '3' },
index a095e11e4a2cc43a00bca7452ed986735a6da78e..0425d20d73e75a97266ce473d5313c8b2cf71239 100644 (file)
@@ -34,7 +34,7 @@ static void help(void)
               "\n", IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        {"add-set",   1, 0, '1'},
        {"del-set",   1, 0, '2'},
        {0}
index a18e36a965c6a986038bd54edf3f59e187e6e5c8..9460612dfd4658afb53e6c835ed5fb1b69114383 100644 (file)
@@ -32,7 +32,7 @@ help(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "to-source", 1, 0, '1' },
        { "random", 0, 0, '2' },
        { 0 }
index b1e7186a226fe4bb97ee925e9388c878e35b37bd..d6b8c36d475c00534c109432ec06b237d017c335 100644 (file)
@@ -14,7 +14,7 @@ struct tosinfo {
 };
 
 /* TOS names and values. */
-static
+static const
 struct TOS_value
 {
        unsigned char TOS;
@@ -47,7 +47,7 @@ IPTABLES_VERSION);
        fputc('\n', stdout);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "set-tos", 1, 0, '1' },
        { 0 }
 };
index 6110e0eb016dab369bda478fb57f2d39fdb88808..fa3205a1449ad21ebfa287d17fe116d90b025d99 100644 (file)
@@ -138,7 +138,7 @@ static void print(const void *ip,
        printf("%u ", info->ttl);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "ttl-set", 1, 0, '1' },
        { "ttl-dec", 1, 0, '2' },
        { "ttl-inc", 1, 0, '3' },
index 88fc16d938015a56e9ac53987fd07706f374b004..cc65bba973e37939a817e74d3cf43017a0a572f2 100644 (file)
@@ -44,7 +44,7 @@ static void help(void)
               IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        {"ulog-nlgroup", 1, 0, '!'},
        {"ulog-prefix", 1, 0, '#'},
        {"ulog-cprange", 1, 0, 'A'},
index ed8b2046c3516dc5f107205c62dec1c72b640441..f377e90d0f16a8d511bb91f3b1d6abc97ef5a23a 100644 (file)
@@ -12,7 +12,7 @@
 #include <linux/netfilter_ipv4/ipt_addrtype.h>
 
 /* from linux/rtnetlink.h, must match order of enumeration */
-static char *rtn_names[] = {
+static const char *const rtn_names[] = {
        "UNSPEC",
        "UNICAST",
        "LOCAL",
@@ -179,7 +179,7 @@ static void save(const void *ip,
        }
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "src-type", 1, 0, '1' },
        { "dst-type", 1, 0, '2' },
        { 0 }
index 3bc2d8d85e5ef07205bc38c3a6f7bf3aebf37df2..feba38ac6409fe74cd672d72517512eed127cc2c 100644 (file)
@@ -19,7 +19,7 @@ help(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "ahspi", 1, 0, '1' },
        {0}
 };
index 0876cd62d0576fa714f028453d78913b05fab2cb..30391d3582663532ca323716556184338d46ecff 100644 (file)
@@ -19,7 +19,7 @@ help(void)
 }
 
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { .name = "condition", .has_arg = 1, .flag = 0, .val = 'X' },
        { .name = 0 }
 };
index 9b40d5a59d7ab67b497eade19976b9a57ccbf21d..3c20bafa19b1efcceb10141fffa8682c9c7a8b9b 100644 (file)
@@ -20,7 +20,7 @@ help(void)
 "\n", IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "connbytes", 1, 0, '1' },
        { "connbytes-dir", 1, 0, '2' },
        { "connbytes-mode", 1, 0, '3' },
index 86248d9d4236c3d2c02230b65ab3e1b265f4e6c0..31a45549520d38bd210731f765ea1ebb95585112 100644 (file)
@@ -39,7 +39,7 @@ help(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "mark", 1, 0, '1' },
        {0}
 };
index 9a7563e25b40c02dd9049ea08e7f86c953d9d930..a12cd8aa2a2bb0e05736bf4860a48796cbf873f0 100644 (file)
@@ -29,7 +29,7 @@ help(void)
 "\n", IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "connrate", 1, 0, '1' },
        {0}
 };
index b50a58bb2c3d86ebca43d8e10dc274b3e05ad793..d3999cf1836f02fd6e64cf832bfa936cf96de6ca 100644 (file)
@@ -43,7 +43,7 @@ help(void)
 
 
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "ctstate", 1, 0, '1' },
        { "ctproto", 1, 0, '2' },
        { "ctorigsrc", 1, 0, '3' },
index fb68bb92402cb544936970bdd7e63fd5527de105..34aa1d31f7a262ded3c3d7cc91dc60ad0c6b51ac 100644 (file)
@@ -14,7 +14,7 @@
 #include <xtables.h>
 
 
-static struct ds_class
+static const struct ds_class
 {
        const char *name;
        unsigned int dscp;
index 8a5a7d39e0de12a09ff3ae04054d6af69088b435..538966ff49af64ea381df5a5f804a8ffba102ee3 100644 (file)
@@ -26,7 +26,7 @@ static void help(void)
        IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { .name = "ecn-tcp-cwr", .has_arg = 0, .flag = 0, .val = 'F' },
        { .name = "ecn-tcp-ece", .has_arg = 0, .flag = 0, .val = 'G' },
        { .name = "ecn-ip-ect",  .has_arg = 1, .flag = 0, .val = 'H' },
index 552d3bff049e0d3c6c8c3a6231a5b9ac5de0803e..c1cc7cb32910e1ac385838f4bc8f03bc9650d410 100644 (file)
@@ -46,7 +46,7 @@ help(void)
 "\n", IPTABLES_VERSION, IPT_HASHLIMIT_BURST);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "hashlimit", 1, 0, '%' },
        { "hashlimit-burst", 1, 0, '$' },
        { "hashlimit-htable-size", 1, 0, '&' },
index e5772555bf04c5424dc3aed25ee5091528d67d87..c862541dbdbc70e64ad9c941b769b99989f6bbba 100644 (file)
@@ -19,7 +19,7 @@ help(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "helper", 1, 0, '1' },
        {0}
 };
index 21da4ea1c648d797f96bdfc9830d02bf19430439..f46c004abbe3c39bc194e0681d0cdb4faf7920ed 100644 (file)
@@ -109,7 +109,7 @@ help(void)
        print_icmptypes();
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "icmp-type", 1, 0, '1' },
        {0}
 };
index 3a039b12553495e3d78843bec518d6c8c742e6b1..30696aaff2bb92acac7c9737aab257a181557292 100644 (file)
@@ -20,7 +20,7 @@ help(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "src-range", 1, 0, '1' },
        { "dst-range", 1, 0, '2' },
        {0}
index c7217743bf9a21426ae08082cb450d17e527f0a0..03f9b05384b64d928f0bd571e85d530f476a4d19 100644 (file)
@@ -38,7 +38,7 @@ IPTABLES_VERSION);
 #endif /* IPT_OWNER_COMM */
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "uid-owner", 1, 0, '1' },
        { "gid-owner", 1, 0, '2' },
        { "pid-owner", 1, 0, '3' },
index 978edb00c6855bcd534133eab05eba75ad9e8714..97b7d02dc89069dc199d6853596d1be4e6721daa 100644 (file)
@@ -40,7 +40,7 @@ static void help(void)
        IPTABLES_VERSION);
 }
 
-static struct option opts[] =
+static const struct option opts[] =
 {
        {
                .name           = "dir",
index 445bcc82853feffa2d5d259a87bac5c2e8ee5519..0b11457b1da022ba71b42cd2c7e3fa111faac425 100644 (file)
@@ -25,7 +25,7 @@ help(void)
 "\n", IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "realm", 1, 0, '1' },
        {0}
 };
index 38d58711774e86fe36d42385a3e5f09a0edfd842..94721b3fdabd3ad8eb923b39e603946180f85be9 100644 (file)
@@ -22,7 +22,7 @@
 #endif /* IPT_RECENT_NAME_LEN */
 
 /* Options for this module */
-static struct option opts[] = {
+static const struct option opts[] = {
        { .name = "set",      .has_arg = 0, .flag = 0, .val = 201 }, 
        { .name = "rcheck",   .has_arg = 0, .flag = 0, .val = 202 }, 
        { .name = "update",   .has_arg = 0, .flag = 0, .val = 203 },
index 4bd9bd229b9a3b251eaf1bc20a48d808cbd53693..d5cc1c3ef9eda0a046a852379b182d0b452025d0 100644 (file)
@@ -32,7 +32,7 @@ static void help(void)
               "\n", IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        {"set", 1, 0, '1'},
        {0}
 };
index a6d9dc37f44cc15265b0629f2b18a933f2d2cf54..c4e5ef3a4d03afaf081fa667ed4f33cabfed1ff0 100644 (file)
@@ -23,7 +23,7 @@ help(void)
 "\n", IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "state", 1, 0, '1' },
        {0}
 };
index 52357ec0400df8d33c08b1e30c4fc5550b8bef3e..21122591b77ec2cb1fd9b692eb75f2ada8ecba05 100644 (file)
@@ -23,7 +23,7 @@ help(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "mode", 1, 0, '1' },
        { "probability", 1, 0, '2' },
        { "every", 1, 0, '3' },
index efc216c4fbc7a23980d713b30cb2d20eeb879061..2f5f9159e86de4836ae5ec7a5c308122034b3ec1 100644 (file)
@@ -9,7 +9,7 @@
 #include <linux/netfilter_ipv4/ipt_tos.h>
 
 /* TOS names and values. */
-static
+static const
 struct TOS_value
 {
        unsigned char TOS;
@@ -42,7 +42,7 @@ IPTABLES_VERSION);
        fputc('\n', stdout);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "tos", 1, 0, '1' },
        {0}
 };
index 5409deec38bb6e5c47657df8b7bb64cc98fce737..f5602f5eacde86f534c7bb91cee3d2a377b4608a 100644 (file)
@@ -143,7 +143,7 @@ static void save(const void *ip,
        printf("%u ", info->ttl);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "ttl", 1, 0, '2' },
        { "ttl-eq", 1, 0, '2'},
        { "ttl-lt", 1, 0, '3'},
index 7b3dceccc636af55af3bcaa2b650f3ab605dd099..c5e73250068c2438abcd2225c485bb8ae39f83b4 100644 (file)
@@ -27,7 +27,7 @@ static void help(void)
 );
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "queue-num", 1, 0, 'F' },
        { 0 }
 };
index 8bf19bce90f8a78cae9f4e8e9e7d4ac41c6b1603..11a617b7184f4411fb1c0e8eb21a032a79aff573 100644 (file)
@@ -23,7 +23,7 @@ static void help(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "selctx", 1, 0, '1' },
        { 0 }
 };
index cd2fc420e65a86e7a8a644b2d282957de4ee503e..12b4cb61abfe9f36ce179707c6653399024d5174 100644 (file)
@@ -36,7 +36,7 @@ static void help6(void)
        __help(60);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "set-mss", 1, 0, '1' },
        { "clamp-mss-to-pmtu", 0, 0, '2' },
        { 0 }
index 770a3ec556c0b5a402f432fd4122871411509a91..db45ab668fcc582ce8246467cf456b1627f4d880 100644 (file)
@@ -24,7 +24,7 @@ help(void)
                );
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "comment", 1, 0, '1' },
        {0}
 };
index f4918dd7de587dff33c9fac5746a65dd5881a70e..45c7e380107a70cafb940905489462e4af19a0a7 100644 (file)
@@ -46,7 +46,7 @@ static void help(void)
        IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { .name = "source-port", .has_arg = 1, .flag = 0, .val = '1' },
        { .name = "sport", .has_arg = 1, .flag = 0, .val = '1' },
        { .name = "destination-port", .has_arg = 1, .flag = 0, .val = '2' },
index 3f5f6c64cee93222aaf0c9cd99f4883d062cabf9..e2de94063cc63228993db795f70c3ef1fb876c07 100644 (file)
@@ -39,7 +39,7 @@ static void help(void)
 );
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "dscp", 1, 0, 'F' },
        { "dscp-class", 1, 0, 'G' },
        { 0 }
index 7eb030e8e29f1a2330508bb8bd5a296b588cea0d..6836dfc3486d6a63718b887daaa868e0f4b34b64 100644 (file)
@@ -19,7 +19,7 @@ help(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "espspi", 1, 0, '1' },
        {0}
 };
index 345423d76d2e4ccefa142c0202f8709dfbaf4e9a..46a4ad2cc98f57b408d2ad3b5b9d215d3f564275 100644 (file)
@@ -20,7 +20,7 @@ IPTABLES_VERSION);
 
 }
   
-static struct option opts[] = {
+static const struct option opts[] = {
        { "length", 1, 0, '1' },
        {0}
 };
index c85536bd13990f66d553e24b78c3cfa87fd2bc88..f8c9e6410a759f15610246aace2adeb949fd4e6a 100644 (file)
@@ -30,7 +30,7 @@ help(void)
 "\n", IPTABLES_VERSION, XT_LIMIT_BURST);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "limit", 1, 0, '%' },
        { "limit-burst", 1, 0, '$' },
        { 0 }
index b907594c578738549400d7eec6427de223c5c21c..b935ea554447ebbf0d7e1286d5f1ed5b3bf6bfda 100644 (file)
@@ -23,7 +23,7 @@ help(void)
 "\n", IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "mac-source", 1, 0, '1' },
        {0}
 };
index 04104d1340c0976c1ea51bc17292654140dec833..23643dcd1f8b89fa5ec85a82539163dd7fef33a3 100644 (file)
@@ -20,7 +20,7 @@ help(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "mark", 1, 0, '1' },
        {0}
 };
index 274a58301adebf97c84604ac809b6a4e68dc2190..f7e67daa3343b9b115af9c3e564554ad482ceac5 100644 (file)
@@ -45,7 +45,7 @@ help_v1(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "source-ports", 1, 0, '1' },
        { "sports", 1, 0, '1' }, /* synonym */
        { "destination-ports", 1, 0, '2' },
index 0f862c0cdcb154be3756b81c8f796156c73da7e3..551747244874183fbedfe24449f8358ce7fde666 100644 (file)
@@ -25,7 +25,7 @@ help(void)
 "\n", IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "physdev-in", 1, 0, '1' },
        { "physdev-out", 1, 0, '2' },
        { "physdev-is-in", 0, 0, '3' },
index 81cd943e160da99cac409df45a045e5f944aecf9..3732034cbc79b22b79144402c26b52af78aa64f2 100644 (file)
@@ -64,7 +64,7 @@ static void help(void)
        print_types();
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        {"pkt-type", 1, 0, '1'},
        {0}
 };
index f97f02cdc09b1b445113d690b9971ae2d2072dbe..ab4fb96fb34537b6c4409b6476077d78eef10e3c 100644 (file)
@@ -11,7 +11,7 @@
 
 #include <linux/netfilter/xt_quota.h>
 
-static struct option opts[] = {
+static const struct option opts[] = {
         {"quota", 1, 0, '1'},
         {0}
 };
index 5d23f091717935f03f1a7dffbc8ad535dc4b4d41..734e706a8c8135f9daf21910c3dfa2ea359fa7e6 100644 (file)
@@ -69,7 +69,7 @@ static void help(void)
        IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { .name = "source-port", .has_arg = 1, .flag = 0, .val = '1' },
        { .name = "sport", .has_arg = 1, .flag = 0, .val = '1' },
        { .name = "destination-port", .has_arg = 1, .flag = 0, .val = '2' },
index c58f4814da1aa439257461acd21a44c13d2df819..ea0a2aa43cfa3b7002aa83d5fc4cc20e18921834 100644 (file)
@@ -44,7 +44,7 @@ help(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "from", 1, 0, '1' },
        { "to", 1, 0, '2' },
        { "algo", 1, 0, '3' },
index da4922b6a83ea0ae4cfa7b42cda484e60d13adee..e5db6376f2fdd92ec98f90f41be0461ae601225f 100644 (file)
@@ -27,7 +27,7 @@ help(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "source-port", 1, 0, '1' },
        { "sport", 1, 0, '1' }, /* synonym */
        { "destination-port", 1, 0, '2' },
index 4b421b21261431c51b948626d84580a9c8970738..817578a120aa096f52593eb0d556f2681b00995f 100644 (file)
@@ -19,7 +19,7 @@ help(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "mss", 1, 0, '1' },
        {0}
 };
index 6942043fa9bbfd90178d92a5547c8b61f4862753..81ff3145b6354968858cdfe12ded243908f31d50 100644 (file)
@@ -22,7 +22,7 @@ help(void)
 IPTABLES_VERSION);
 }
 
-static struct option opts[] = {
+static const struct option opts[] = {
        { "source-port", 1, 0, '1' },
        { "sport", 1, 0, '1' }, /* synonym */
        { "destination-port", 1, 0, '2' },