[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Help-bash] Prevent file descriptor inheritance

From: Greg Wooledge
Subject: Re: [Help-bash] Prevent file descriptor inheritance
Date: Wed, 8 Aug 2018 09:32:40 -0400
User-agent: NeoMutt/20170113 (1.7.2)

On Wed, Aug 08, 2018 at 03:28:28PM +0200, R. Diez wrote:
> I am just planning the script, I have not written it yet.
> Say I am using the file in a loop. If I close the file descriptor every time
> before I run an external tool, I have to reopen the file and seek to the
> last read position. Not very convenient.

It would help to know a bit more about this file.  Can't you simply
read the contents from it, and then close it?  Is there a reason you
need to keep it open for a long time, but still want to prevent child
processes from gaining access?

reply via email to

[Prev in Thread] Current Thread [Next in Thread]