in reply to Re: Knowing an IO::Socket handle has
in thread Knowing an IO::Socket handle has reached end-of-file
No, eof doesn't work. On a socket you are ever at eof, if no data are pending.
But if you read with <> not into an array, but into a single variable, perl has no choice
and returns a single line (including the eol-char, but not at eof, where it is an empty string)