
perlbug-followup at perl
Nov 22, 2011, 7:03 PM
Post #1 of 3
(151 views)
Permalink
|
|
[perl #7747] <> vs <STDIN> is OS specific
|
|
> > I wrote a simple STDIN inline filter that puts a command in > the path of STDIN. It sends STDIN to open2, and then takes the > output of that and dups it back to STDIN. > > When I then read from <> (as opposed to <STDIN>), I get nothing > on a linux box (tested with 5.005, 5.004, 5.6.0 and 5.6.1), but > it works fine on other OS (at least Solaris). > I ran the attached program, commenting out first one 'while' loop and then the other, on both Darwin and Linux, with Perl 5.14. In all cases, the program simply hung; none of the 'print' statements ever materialized. So either I misunderstood what I was supposed to be doing, or the program still does not work. Should it have? Thank you very much. Jim Keenan
|