diff options
author | Bart De Schuymer <bdschuym@pandora.be> | 2003-04-01 06:31:46 +0000 |
---|---|---|
committer | Bart De Schuymer <bdschuym@pandora.be> | 2003-04-01 06:31:46 +0000 |
commit | fa95f496edd2a7bb72a2b1491de447454df04487 (patch) | |
tree | 57ea0b3c82e49a54c9a041d488c33ff899ef9b41 | |
parent | 5f4d378dc7d22e371b12f248d5325836e401e4fa (diff) |
fix compare bug
-rw-r--r-- | userspace/ebtables2/extensions/ebt_ip.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/userspace/ebtables2/extensions/ebt_ip.c b/userspace/ebtables2/extensions/ebt_ip.c index 76da2b7..1e1504c 100644 --- a/userspace/ebtables2/extensions/ebt_ip.c +++ b/userspace/ebtables2/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; |