summaryrefslogtreecommitdiffstats
path: root/userspace/ebtables2/extensions/ebt_vlan.c
diff options
context:
space:
mode:
authorBart De Schuymer <bdschuym@pandora.be>2005-01-19 21:09:05 +0000
committerBart De Schuymer <bdschuym@pandora.be>2005-01-19 21:09:05 +0000
commit98984a8c623b592ddfb3b30ac92615422849eab3 (patch)
tree04f8b52a474e2ea45a4e3527369233ce783883a2 /userspace/ebtables2/extensions/ebt_vlan.c
parent0c7965d9957b91c1027255de29e81f408f8ca8a7 (diff)
add ebtablesu scheme, along with general cleanup
Diffstat (limited to 'userspace/ebtables2/extensions/ebt_vlan.c')
-rw-r--r--userspace/ebtables2/extensions/ebt_vlan.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/userspace/ebtables2/extensions/ebt_vlan.c b/userspace/ebtables2/extensions/ebt_vlan.c
index b4e1d38..0c94a66 100644
--- a/userspace/ebtables2/extensions/ebt_vlan.c
+++ b/userspace/ebtables2/extensions/ebt_vlan.c
@@ -141,8 +141,7 @@ parse(int c,
ebt_check_option(flags, OPT_VLAN_ID);
CHECK_INV_FLAG(EBT_VLAN_ID);
CHECK_IF_MISSING_VALUE;
- (unsigned short) local.id =
- strtoul(argv[optind - 1], &end, 10);
+ local.id = strtoul(argv[optind - 1], &end, 10);
CHECK_RANGE(local.id > 4094 || *end != '\0');
vlaninfo->id = local.id;
SET_BITMASK(EBT_VLAN_ID);
@@ -152,8 +151,7 @@ parse(int c,
ebt_check_option(flags, OPT_VLAN_PRIO);
CHECK_INV_FLAG(EBT_VLAN_PRIO);
CHECK_IF_MISSING_VALUE;
- (unsigned char) local.prio =
- strtoul(argv[optind - 1], &end, 10);
+ local.prio = strtoul(argv[optind - 1], &end, 10);
CHECK_RANGE(local.prio >= 8 || *end != '\0');
vlaninfo->prio = local.prio;
SET_BITMASK(EBT_VLAN_PRIO);
@@ -163,8 +161,7 @@ parse(int c,
ebt_check_option(flags, OPT_VLAN_ENCAP);
CHECK_INV_FLAG(EBT_VLAN_ENCAP);
CHECK_IF_MISSING_VALUE;
- (unsigned short) local.encap =
- strtoul(argv[optind - 1], &end, 16);
+ local.encap = strtoul(argv[optind - 1], &end, 16);
if (*end != '\0') {
ethent = getethertypebyname(argv[optind - 1]);
if (ethent == NULL)