summaryrefslogtreecommitdiff
path: root/extensions
diff options
context:
space:
mode:
authorBart De Schuymer <bdschuym@pandora.be>2003-04-01 06:31:46 +0000
committerBart De Schuymer <bdschuym@pandora.be>2003-04-01 06:31:46 +0000
commitfd529b716c16b89dc7070b01a4f9cb4ee255ccc5 (patch)
tree95da6a87de1bd41070bf630f7a2b375fa252ee9b /extensions
parentff852cec560ea90b8d273cdf0c5dfe097af9f412 (diff)
downloadebtables-fd529b716c16b89dc7070b01a4f9cb4ee255ccc5.tar.gz
ebtables-fd529b716c16b89dc7070b01a4f9cb4ee255ccc5.tar.bz2
ebtables-fd529b716c16b89dc7070b01a4f9cb4ee255ccc5.zip
fix compare bug
Diffstat (limited to 'extensions')
-rw-r--r--extensions/ebt_ip.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/extensions/ebt_ip.c b/extensions/ebt_ip.c
index 76da2b7..1e1504c 100644
--- a/extensions/ebt_ip.c
+++ b/extensions/ebt_ip.c
@@ -443,11 +443,13 @@ static int compare(const struct ebt_entry_match *m1,
return 0;
}
if (ipinfo1->bitmask & EBT_IP_SPORT) {
- if (ipinfo1->sport != ipinfo2->sport)
+ if (ipinfo1->sport[0] != ipinfo2->sport[0] ||
+ ipinfo1->sport[1] != ipinfo2->sport[1])
return 0;
}
if (ipinfo1->bitmask & EBT_IP_DPORT) {
- if (ipinfo1->dport != ipinfo2->dport)
+ if (ipinfo1->dport[0] != ipinfo2->dport[0] ||
+ ipinfo1->dport[1] != ipinfo2->dport[1])
return 0;
}
return 1;