summaryrefslogtreecommitdiffstats
path: root/extensions/libxt_state.c
diff options
context:
space:
mode:
authorJan Engelhardt <jengelh@medozas.de>2008-02-11 00:33:30 +0100
committerPatrick McHardy <kaber@trash.net>2008-04-06 17:43:13 +0200
commitdbb77543ad6afe29e9a1881b2d4fc212de621a55 (patch)
tree52cdf11fded05c39431fc612891253044d0ee9f2 /extensions/libxt_state.c
parent7a236f4cc685a420c1a782a5db614a93baf37ccf (diff)
Fix -Wshadow warnings and clean up xt_sctp.h
Note: xt_sctp.h is still not merged upstream in the kernel as of this commit. But a refactoring was really needed.
Diffstat (limited to 'extensions/libxt_state.c')
-rw-r--r--extensions/libxt_state.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/extensions/libxt_state.c b/extensions/libxt_state.c
index 68f52808..5b8beea1 100644
--- a/extensions/libxt_state.c
+++ b/extensions/libxt_state.c
@@ -29,17 +29,17 @@ static const struct option state_opts[] = {
};
static int
-state_parse_state(const char *state, size_t strlen, struct xt_state_info *sinfo)
+state_parse_state(const char *state, size_t len, struct xt_state_info *sinfo)
{
- if (strncasecmp(state, "INVALID", strlen) == 0)
+ if (strncasecmp(state, "INVALID", len) == 0)
sinfo->statemask |= XT_STATE_INVALID;
- else if (strncasecmp(state, "NEW", strlen) == 0)
+ else if (strncasecmp(state, "NEW", len) == 0)
sinfo->statemask |= XT_STATE_BIT(IP_CT_NEW);
- else if (strncasecmp(state, "ESTABLISHED", strlen) == 0)
+ else if (strncasecmp(state, "ESTABLISHED", len) == 0)
sinfo->statemask |= XT_STATE_BIT(IP_CT_ESTABLISHED);
- else if (strncasecmp(state, "RELATED", strlen) == 0)
+ else if (strncasecmp(state, "RELATED", len) == 0)
sinfo->statemask |= XT_STATE_BIT(IP_CT_RELATED);
- else if (strncasecmp(state, "UNTRACKED", strlen) == 0)
+ else if (strncasecmp(state, "UNTRACKED", len) == 0)
sinfo->statemask |= XT_STATE_UNTRACKED;
else
return 0;