[vdr] [patch] avoid inheritance of file descriptors
Klaus.Schmidinger at cadsoft.de
Tue Dec 11 09:21:52 CET 2007
On 12/11/2007 08:39 AM, Deti Fliegl wrote:
> Klaus Schmidinger wrote:
>> Plugins can call SystemExec() just as well when the want to execute
>> an external program.
> Yes, but would you point every single developer on this issue?
>> IMHO it is no feasible solution to expect every file handle to
>> be opened with FD_CLOEXEC. Even if VDR itself would do this, there
>> could still be plugins that don't.
> It is enough to let VDR set this flag on its own file handles - the main
> problem is that while an external script/program is running and because
> of inherited DVB handles
> - zapping is blocked
> - a restart of VDR is impossible.
>> I'd say if some plugin wants to run an external program, it needs
>> to take care by itself that all unneeded file handles are closed.
>> That's what SystemExec() is for.
> Whatever - if you don't see the point I cannot help.
Why is this suddenly such a big problem?
If a plugin wants to run an external program it can simply
Besides, as Darren Salt pointed out, this flag is apparently
only available in the very latest kernel version, which I'm
pretty sure is not that widely in use yet.
More information about the vdr