in reply to Re^2: filehandle/socket question (seek)
in thread filehandle/socket question

In that case, dup(2)ing the file handle is probably a better idea:

open IN, "<&SOCKET" or die ...;

though selecting a suitable non-bareword file handle scheme is even better.

my $in = ...; open $in, "<&".fileno($sock) or die ...;

Where the first "..." depends on what you find appropriate. "undef" works for modern versions of Perl. Or you can use IO::Handle or other module or just do { local(*IN); \*IN }.

- tye