[Haskell-beginners] System.Process.createProcess [solved]

John Obbele john.obbele at gmail.com
Sun Jun 27 07:05:19 EDT 2010


On Sat, Jun 26, 2010 at 08:59:01PM -0400, Brandon S Allbery KF8NH wrote:
> On 6/26/10 18:57 , John Obbele wrote:
> > After digging things a little, it seems I am messing with the
> > System.Process.createProcess function : none of my spawned
> > process terminates and eventually my OS freezes.
> 
> You need to reap zombies manually; take a look at
> System.Process.waitForProcess.  (On POSIX-ish systems, including Linux, you
> can use the signal handling functions to auto-reap; on Linux simply setting
> SIGCHLD to SIG_IGN is good enough, but other systems (*BSD, OSX) require you
> to also set the SA_NOCLDWAIT flag and for portability you should include it.
>  (Which, I note, doesn't seem to be supported in System.Posix.Signals.  O
> Haskell gods:  Bug?)

Oki, I've test with waitForProcess and it's working fine. Thanks
for your help :)

And concerning the signals part, I've never heard of managing
child processes with them. I will go reread some docs about
it, I may learn some new interesting things today ...

regards,
/john


More information about the Beginners mailing list