Hello,The System.Process.runInteractiveProcess functiondoesn't seem to provide the child process with a stdinhandle when the parent's stdin is closed. Below is asmall example:import System.Processimport Control.Concurrentimport System.IOmain = do hClose stdin -- everything works as expected if thehandle isn't closed. putStrLn "Running cat ..." (inp, out, err, pid) <- runInteractiveProcess "cat"[] Nothing Nothing forkIO (hPutStrLn inp "foo" >> hClose inp) forkIO (putStrLn =<< hGetContents out) forkIO (putStrLn =<< hGetContents err) -- Don't want to deal with waitForProcess and-threaded right now. threadDelay 1000000 return ()Running this example produces the error% ghc Run.hs -o run% ./runRunning cat ...cat: -: Bad file descriptorcat: closing standard input: Bad file descriptorI think the bug is infptools/libraries/base/cbits/runProcess.c://... pipe(fdStdInput);//... dup2 (fdStdInput[0], STDIN_FILENO);/... close(fdStdInput[0]);//...pipe(...) will assign the lowest available filedescriptors, i.e. 0 if stdin is closed. The dup2 won'tdo anything, since src and dest fds are identical, soclose(...) will close the child's stdin immediately.% uname -aLinux mthomas 2.6.12 #2 Thu Jul 21 07:51:44 EDT 2005i686 GNU/Linux% ghc --versionThe Glorious Glasgow Haskell Compilation System,version 6.5.20050728Thanks,-- Thomas Jäger