in reply to how to read STDIN interactively

Once you set $/ to undef, <...> will keep reading until the filehandle is exhausted. After that, you will likely need to reopen STDIN to start reading from it again.

Replies are listed 'Best First'.
Re^2: how to read STDIN interactively
by ikegami (Patriarch) on Feb 24, 2011 at 16:11 UTC
    No, not if STDIN is a terminal. Terminals automatically re-open, in effect. That's what you can rely on read functions to return EOF more than once, and why you sometimes have to signal EOF more than once to exit some applications.