Quoth Erik de Castro Lopo <mle...@mega-nerd.com>, ... > The code below *almost* works. Its currently printing out: > > parent : Forked child was here! > parent : Message from parent. > Read 21 bytes > > while I think it should print: > > parent : Forked child was here! > parent : Read 21 bytes > > Any clues on why 'Message from parent.' is also ending up on > stdout? This is ghc-6.12.1 on Debian Linux.
My guess is that the default tty attributes include ECHO. So the data you write to the master fd is echoed back, as though by the fork process but actually by the terminal driver. You can turn ECHO off. Donn Cave, d...@avvanta.com _______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe