in reply to Re: IPC via named pipes, losing some messages
in thread IPC via named pipes, losing some messages
Which didn't work, I'm still missing some messages. So, assuming the problem is with buffered IO, I thought I'd try:local $/; open PIPE, "<$pipe"; my $data = <PIPE>; close PIPE;
Which is also not working. I am stumped. I could open the pipe out of the loop, but then it wouldn't block on the open and I'd rather not sleep to simulate that. Any ideas?open FH, "<$config->{'pipe'}"; my $data; while (sysread FH, my $buf, 2048) { $data .= $buf; } close FH;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: IPC via named pipes, losing some messages
by pc88mxer (Vicar) on Apr 14, 2008 at 15:37 UTC |