]> git.ipfire.org Git - thirdparty/iptables.git/commitdiff
check for --table as well as -t (Andreas Ferber)
authorHarald Welte <laforge@gnumonks.org>
Mon, 22 Oct 2001 15:16:21 +0000 (15:16 +0000)
committerHarald Welte <laforge@gnumonks.org>
Mon, 22 Oct 2001 15:16:21 +0000 (15:16 +0000)
ip6tables-restore.c
iptables-restore.c

index 415f1e4d35152401d118dd2c0c8d9adbbd2404f2..1b54b237e396be82ba6cb3825ef3944f64d87ae3 100644 (file)
@@ -343,7 +343,8 @@ int main(int argc, char *argv[])
                                                 param_len);
                                         *(param_buffer+param_len) = '\0';
 
-                                       if (!strncmp(param_buffer, "-t", 3)) {
+                                       if (!strncmp(param_buffer, "-t", 3)
+                                            || !strncmp(param_buffer, "--table", 8)) {
                                                exit_error(PARAMETER_PROBLEM, 
                                                   "Line %u seems to have a "
                                                   "-t table option.\n", line);
index 2a18a0950a49b8c8ac4d8e0b3b9bea40e650b70c..fe70aae5f9c13f9bf8f46d22d9ae016cb56f35d9 100644 (file)
@@ -4,7 +4,7 @@
  *
  * This coude is distributed under the terms of GNU GPL
  *
- * $Id: iptables-restore.c,v 1.16 2001/10/16 09:51:33 laforge Exp $
+ * $Id: iptables-restore.c,v 1.17 2001/10/21 14:11:54 laforge Exp $
  */
 
 #include <getopt.h>
@@ -338,7 +338,8 @@ int main(int argc, char *argv[])
                                        *(param_buffer+param_len) = '\0';
 
                                        /* check if table name specified */
-                                       if (!strncmp(param_buffer, "-t", 3)) {
+                                       if (!strncmp(param_buffer, "-t", 3)
+                                            || !strncmp(param_buffer, "--table", 8)) {
                                                exit_error(PARAMETER_PROBLEM, 
                                                   "Line %u seems to have a "
                                                   "-t table option.\n", line);