projects
/
GitHub
/
exynos8895
/
android_kernel_samsung_universal8895.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9ab4c95
)
[NETFILTER]: xt_hashlimit should use time_after_eq()
author
Eric Dumazet
<dada1@cosmosbay.com>
Wed, 12 Dec 2007 19:11:28 +0000
(11:11 -0800)
committer
David S. Miller
<davem@sunset.davemloft.net>
Fri, 14 Dec 2007 21:54:36 +0000
(13:54 -0800)
In order to avoid jiffies wraparound and its effect, special care must
be taken
when doing comparisons ...
Signed-off-by: Eric Dumazet <dada1@cosmosbay.com>
Acked-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/netfilter/xt_hashlimit.c
patch
|
blob
|
blame
|
history
diff --git
a/net/netfilter/xt_hashlimit.c
b/net/netfilter/xt_hashlimit.c
index 19103678bf2079bb3b4c3c937a6992744711bca1..2ef44d8560c154d944ea66e28e6505bc77c6222e 100644
(file)
--- a/
net/netfilter/xt_hashlimit.c
+++ b/
net/netfilter/xt_hashlimit.c
@@
-240,7
+240,7
@@
static bool select_all(const struct xt_hashlimit_htable *ht,
static bool select_gc(const struct xt_hashlimit_htable *ht,
const struct dsthash_ent *he)
{
- return
jiffies >= he->expires
;
+ return
time_after_eq(jiffies, he->expires)
;
}
static void htable_selective_cleanup(struct xt_hashlimit_htable *ht,