in reply to Malfunctioning select() call on a FIFO

You're using sysread, right? When sysread return zero bytes read, it indicates EOF. For a fifo, that means the other end of the fifo was closed. The fifo is still closed every subsequent time you call select, so select keeps signaling that the handle needs to be serviced. Similarly, if sysread returns undef, it indicates an error occurred.

Update: Disambiguated pronouns and clarified what EOF means for a fifo.

Replies are listed 'Best First'.
Re^2: Malfunctioning select() call on a FIFO
by Llew_Llaw_Gyffes (Scribe) on Jan 06, 2010 at 18:18 UTC

    I tried switching to a sysread(FIFO, ...) from using <FIFO> in the hopes that it might solve the problem, yes. It didn't make any difference, though. What's puzzling me is that this code USED to work, and now it doesn't, but the code hasn't been changed between when it worked and now.