in reply to Re: How do you properly tty-ify a non-tty STDOUT?
in thread How do you properly tty-ify a non-tty STDOUT?

By the way (and I could be confused, my brain has been dragged through the mud today a few times) - the forking sample code actually does have the parent continuing the flow of execution, with the child doing the system();exit();. The return $pty if $child; line looks in english like it's the other way around, but the parent gets $child defined as a pid number, and the actual child gets $child returned as zero. Therefore the idiom $child = fork; XXX if $child; is very ugly, as the perl meaning is the opposite of the english meaning. Don't blame me, I stole it from an example in a web copy of Chapter 6 of "Network programming with Perl". :)