summaryrefslogtreecommitdiffstats
path: root/extensions/libxt_SET.c
diff options
context:
space:
mode:
authorJozsef Kadlecsik <kadlec@blackhole.kfki.hu>2011-01-21 21:55:05 +0100
committerJozsef Kadlecsik <kadlec@blackhole.kfki.hu>2011-01-21 21:55:05 +0100
commit6f03bf79952753fbc0dc8611aa4d6e70a108dbc7 (patch)
tree091e4917a53dfa03084872e9144ff32e70aefd49 /extensions/libxt_SET.c
parentf46f8c1c5b6d9f5685b9d945e95647eaf6c2d35b (diff)
Fix listing/saving the new revision of the SET target
Instead of the dimension of the set, the max dimension was used at listing/saving the src,dst parameters, which produced broken output.
Diffstat (limited to 'extensions/libxt_SET.c')
-rw-r--r--extensions/libxt_SET.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/extensions/libxt_SET.c b/extensions/libxt_SET.c
index 2d186c58..37da6ec1 100644
--- a/extensions/libxt_SET.c
+++ b/extensions/libxt_SET.c
@@ -215,7 +215,7 @@ print_target(const char *prefix, const struct xt_set_info *info)
return;
get_set_byid(setname, info->index);
printf("%s %s", prefix, setname);
- for (i = 1; i <= IPSET_DIM_MAX; i++) {
+ for (i = 1; i <= info->dim; i++) {
printf("%s%s",
i == 1 ? " " : ",",
info->flags & (1 << i) ? "src" : "dst");