summaryrefslogtreecommitdiffstats
path: root/iptables/xtables-restore.c
diff options
context:
space:
mode:
Diffstat (limited to 'iptables/xtables-restore.c')
-rw-r--r--iptables/xtables-restore.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/iptables/xtables-restore.c b/iptables/xtables-restore.c
index 9d15593f..d9faa4d0 100644
--- a/iptables/xtables-restore.c
+++ b/iptables/xtables-restore.c
@@ -266,7 +266,6 @@ void xtables_restore_parse(struct nft_handle *h,
} else if (in_table) {
int a;
- char *ptr = buffer;
char *pcnt = NULL;
char *bcnt = NULL;
char *parsestart;
@@ -276,7 +275,8 @@ void xtables_restore_parse(struct nft_handle *h,
if (buffer[0] == '[') {
/* we have counters in our input */
- ptr = strchr(buffer, ']');
+ char *ptr = strchr(buffer, ']');
+
if (!ptr)
xtables_error(PARAMETER_PROBLEM,
"Bad line %u: need ]\n",