summaryrefslogtreecommitdiffstats
path: root/extensions/libxt_hashlimit.c
diff options
context:
space:
mode:
authorJan Engelhardt <jengelh@medozas.de>2010-06-24 21:13:47 +0200
committerJan Engelhardt <jengelh@medozas.de>2010-06-24 21:13:47 +0200
commitdd2bbe0b614ad60fb2e267863471836aae424425 (patch)
treec12c4792e21970ec7bdbc883c5e69733b124993a /extensions/libxt_hashlimit.c
parent11c2dd54b69e06ae3f35dea130ecba3df3859243 (diff)
libxt_hashlimit: always print burst value
iptables -L lists the burst value, and so should iptables -S. I was certainly surprised to see it gone even when explicitly specifying --hashlimit-burst 5 on the command line. Signed-off-by: Jan Engelhardt <jengelh@medozas.de>
Diffstat (limited to 'extensions/libxt_hashlimit.c')
-rw-r--r--extensions/libxt_hashlimit.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/extensions/libxt_hashlimit.c b/extensions/libxt_hashlimit.c
index a8fe588f..7442dfcf 100644
--- a/extensions/libxt_hashlimit.c
+++ b/extensions/libxt_hashlimit.c
@@ -591,8 +591,7 @@ static void hashlimit_save(const void *ip, const struct xt_entry_match *match)
const struct xt_hashlimit_info *r = (const void *)match->data;
fputs("--hashlimit ", stdout); print_rate(r->cfg.avg);
- if (r->cfg.burst != XT_HASHLIMIT_BURST)
- printf("--hashlimit-burst %u ", r->cfg.burst);
+ printf("--hashlimit-burst %u ", r->cfg.burst);
fputs("--hashlimit-mode ", stdout);
print_mode(r->cfg.mode, ',');
@@ -617,8 +616,7 @@ hashlimit_mt_save(const struct xt_hashlimit_mtinfo1 *info, unsigned int dmask)
else
fputs("--hashlimit-upto ", stdout);
print_rate(info->cfg.avg);
- if (info->cfg.burst != XT_HASHLIMIT_BURST)
- printf("--hashlimit-burst %u ", info->cfg.burst);
+ printf("--hashlimit-burst %u ", info->cfg.burst);
if (info->cfg.mode & (XT_HASHLIMIT_HASH_SIP | XT_HASHLIMIT_HASH_SPT |
XT_HASHLIMIT_HASH_DIP | XT_HASHLIMIT_HASH_DPT)) {