
26 Oct
2004
26 Oct
'04
5:29 p.m.
Hello, I'm having a little weird situation here. Whenever I call exitFailure under forkProcess, I get: (progname): forkProcess: uncaught exception Test program: import System.Exit import System.Posix.Process main = forkProcess exitFailure If you remove the forkProcess call, the program properly silently exits with exit code 1. I have no idea why it is displaying this message to stderr when called under forkProcess. I argue that it shouldn't. It is perfectly valid to return with an error code from a child process, and absolutely necessary in some cases when your later waitpid() call needs to know what happened. (Or, in Haskell, getProcessStatus()). Thoughts?