[Mono-dev] close on exec

Kornél Pál kornelpal at gmail.com
Tue Sep 30 16:12:50 EDT 2008

Jacob Gladish wrote:
> This is exactly my problem. I do not have source. What I'm left to do is attempt to find all the fd's in question (in my code) and use Mono.Unix.Native.Syscall.fcntl() to set close-on-exec. This obviously doesn't work well since someone else may add new streams to the codebase, and I'm using other 3rd party assemblies (like log4net). 

Mono closes all the file descriptors except stdin, stdout and stderr, so 
  you may try to set this flag on all the file descriptors.


More information about the Mono-devel-list mailing list