All of lore.kernel.org
 help / color / mirror / Atom feed
From: jamal <hadi@cyberus.ca>
To: Denys Fedoryshchenko <denys@visp.net.lb>
Cc: Stephen Hemminger <shemminger@linux-foundation.org>,
	netdev@vger.kernel.org
Subject: Re: few more fixes for iproute2/m_ipt
Date: Wed, 06 Aug 2008 08:46:00 -0400	[thread overview]
Message-ID: <1218026760.4755.60.camel@localhost> (raw)
In-Reply-To: <200808061426.36605.denys@visp.net.lb>

On Wed, 2008-06-08 at 14:26 +0300, Denys Fedoryshchenko wrote:

> Is it better like this?
> 
> Sure optind is up to you, for me it is not clear yet how it works.
> 
> Just i notice in iptables.c, function do_command where they set optind to zero 
> and in comments /*re-set optind to zero in case do_command gets called second 
> time */

I have done extensive testing with and with optind=0 and optind=1 and i
didnt see any breakage with either.

I have a feeling that setting optind to 0 in your case to avoid the
crash maybe hiding something else - but i cant find what that something
else is since i am just simulating what you are doing.
If the iptables folks have changed it to reset to 0, then I dont see any
harm in resetting. 

So ACK to both your patches.

cheers,
jamal
PS:- dont wanna sound anal - and you dont have to do this if you dont
have time; but if you put the resetting of optind and the flags in a
separate patch from the freeing, that would be even better.


  reply	other threads:[~2008-08-06 12:52 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-08-05 21:42 few more fixes for iproute2/m_ipt Denys Fedoryshchenko
2008-08-06 10:04 ` jamal
2008-08-06 10:21   ` Denys Fedoryshchenko
2008-08-06 11:04     ` jamal
2008-08-06 11:26       ` Denys Fedoryshchenko
2008-08-06 12:46         ` jamal [this message]
2008-08-06 12:50           ` Denys Fedoryshchenko
2008-08-06 12:55             ` jamal
2008-08-06 12:56               ` Denys Fedoryshchenko
2008-08-06 12:59               ` Denys Fedoryshchenko
2008-08-06 13:17                 ` jamal
2009-01-07  3:43 ` Stephen Hemminger

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1218026760.4755.60.camel@localhost \
    --to=hadi@cyberus.ca \
    --cc=denys@visp.net.lb \
    --cc=netdev@vger.kernel.org \
    --cc=shemminger@linux-foundation.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.