All of lore.kernel.org
 help / color / mirror / Atom feed
From: Patrick McHardy <kaber@trash.net>
To: Jesper Dangaard Brouer <hawk@diku.dk>
Cc: netfilter-devel@lists.netfilter.org
Subject: Re: Concurrency issues with the iptables userspace program andexitcodes
Date: Thu, 01 Jun 2006 22:45:56 +0200	[thread overview]
Message-ID: <447F5204.4080505@trash.net> (raw)
In-Reply-To: <Pine.LNX.4.61.0606012200260.27621@ask.diku.dk>

Jesper Dangaard Brouer wrote:
> 
> On Thu, 1 Jun 2006, Patrick McHardy wrote:
> 
>> Wouldn't it make more sense to just make sure you don't have iptables
>> commands running concurrently?
> 
> 
> I already have implemented (f)locks in my code around the iptables
> invocations.  But the problem can still arise when root executes the
> iptables command from the shell. Thus, I still need to handle the
> situation in my code, and a proper exitcode would be nice.
> 
> In iptables-standalone.c it would be very easy to simply return the
> errno instead of !res (which always will return 0 or 1).  Would that be
> a feasable solution?

It would probably break other scripts that check for the current
(documented) exit codes. I guess adding a new one for this case
is fine, other code can't really expect that no new values are
ever added.

  reply	other threads:[~2006-06-01 20:45 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-06-01  9:15 Concurrency issues with the iptables userspace program andexitcodes Jesper Dangaard Brouer
2006-06-01 16:13 ` Patrick McHardy
2006-06-01 20:16   ` Jesper Dangaard Brouer
2006-06-01 20:45     ` Patrick McHardy [this message]
2006-06-08 12:52       ` Jesper Dangaard Brouer
2006-06-14 14:05         ` Patrick McHardy
2006-06-14 14:40           ` Jesper Dangaard Brouer
2006-06-19 16:29             ` Patrick McHardy

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=447F5204.4080505@trash.net \
    --to=kaber@trash.net \
    --cc=hawk@diku.dk \
    --cc=netfilter-devel@lists.netfilter.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.