nmh-workers
[Top] [All Lists]

Re: [nmh-workers] closefds() _before_ fork?

2019-04-23 22:34:38
    Date:        Tue, 23 Apr 2019 19:35:11 -0400
    From:        Ken Hornstein <kenh@pobox.com>
    Message-ID:  <20190423233511.EA88B143FB4@pb-smtp1.pobox.com>

  | There are tons of examples like this in nmh; plenty of child processes
  | are created with descriptors open.

It is worth remembering that MH was written before close-on-exec was
invented ... I suspect that much of what you're seeing is simply a
result of that, rather than anything else in particular.

Using close-on-exec sounds like the right way to me, and if it turns
out that some particular uses require a fd to be passed down (which
usually also requires some arg to tell the child which fd that is)
then those can be fixed when discovered.

kre


-- 
nmh-workers
https://lists.nongnu.org/mailman/listinfo/nmh-workers

<Prev in Thread] Current Thread [Next in Thread>