From: Harald Welte Date: Tue, 16 Oct 2001 09:51:33 +0000 (+0000) Subject: fix of-by-one for-loop for debug statement X-Git-Tag: v1.2.4~8 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=fa48fc8eee3047e384cf5958f6c10850cca97632;p=thirdparty%2Fiptables.git fix of-by-one for-loop for debug statement --- diff --git a/iptables-restore.c b/iptables-restore.c index 8465beb1..a6e818e6 100644 --- a/iptables-restore.c +++ b/iptables-restore.c @@ -4,7 +4,7 @@ * * This coude is distributed under the terms of GNU GPL * - * $Id: iptables-restore.c,v 1.14 2001/08/06 18:50:22 laforge Exp $ + * $Id: iptables-restore.c,v 1.15 2001/10/16 07:53:34 laforge Exp $ */ #include @@ -361,7 +361,7 @@ int main(int argc, char *argv[]) DEBUGP("calling do_command(%u, argv, &%s, handle):\n", newargc, curtable); - for (a = 0; a <= newargc; a++) + for (a = 0; a < newargc; a++) DEBUGP("argv[%u]: %s\n", a, newargv[a]); ret = do_command(newargc, newargv,