]> git.ipfire.org Git - thirdparty/iptables.git/commitdiff
iptables-save had problems with multiple spaces between options (A. van Schie)
authorHarald Welte <laforge@gnumonks.org>
Sat, 26 May 2001 04:41:56 +0000 (04:41 +0000)
committerHarald Welte <laforge@gnumonks.org>
Sat, 26 May 2001 04:41:56 +0000 (04:41 +0000)
iptables-restore.c

index 438903ece636c3999d2a8d789132f36f9124f5b3..e5a28f3f6bf63a9cb56d5a2c2dc78eca3b663c45 100644 (file)
@@ -4,7 +4,7 @@
  *
  * This coude is distributed under the terms of GNU GPL
  *
- * $Id: iptables-restore.c,v 1.10 2001/03/15 15:12:02 laforge Exp $
+ * $Id: iptables-restore.c,v 1.11 2001/05/03 20:50:03 laforge Exp $
  */
 
 #include <getopt.h>
@@ -308,8 +308,11 @@ int main(int argc, char *argv[])
                                        if (quote_open)
                                                continue;
 
-                                       if (!param_len)
-                                               break;
+                                       if (!param_len) {
+                                               /* two spaces? */
+                                               param_start++;
+                                               continue;
+                                       }
                                        
                                        /* end of one parameter */
                                        strncpy(param_buffer, param_start,