Skip to contentSkip to conversation

Correct libxt_statistic save output

PATCH Applied Tom Eastep 2 participants 2 messages Nov 17, 2012 – Nov 19, 2012 netfilter

lore
Share & tools
lore

Tom Eastep

author
#0 lore raw

PATCH 1/1 Correct libxt_statistic save output

Suppressing '--packet 0' in save output resulted in restore failure.

This patch includes '--packet 0' in save output while continuing to suppress it in print output.

---
 extensions/libxt_statistic.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
extensions/libxt_statistic.c +0 -0
index 12a83dd..3a6632d 100644
@@ -107,7 +107,7 @@ static void print_match(const struct

xt_statistic_info *info, char *prefix)
(info->flags & XT_STATISTIC_INVERT) ? " !" : "", prefix,
info->u.nth.every + 1);
- if (info->u.nth.packet)
+ if (info->u.nth.packet || *prefix )
printf(" %spacket %u", prefix, info->u.nth.packet);
break;
}

Signature · 7 lines
1.7.2.5

-- 
Tom Eastep        \ When I die, I want to go like my Grandfather who
Shoreline,         \ died peacefully in his sleep. Not screaming like
Washington, USA     \ all of the passengers in his car
http://shorewall.net \________________________________________________
maintainer Applied
#1 lore raw
Quoted 4 lines · Tom Eastep

Suppressing '--packet 0' in save output resulted in restore failure.

This patch includes '--packet 0' in save output while continuing to suppress it in print output.

Applied, thanks Tom!