for here: perlipc.html#Safe-Pipe-Opens
I took and changed:
So this shouldn't be the problem?$pid = open(KID_TO_WRITE, "|-"); if ($pid) { # parent print KID_TO_WRITE @some_data; close(KID_TO_WRITE) || warn "kid exited $?"; } else { # child while (<STDIN>) { ... print ; # child's STDIN is parent's KID } exit; # don't forget this }
In reply to Re^2: forked kid can't read from IO::Select->can_read
by Anonymous Monk
in thread forked kid can't read from IO::Select->can_read
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |