in reply to Sockets + Read

Try sysread.

My guess is that read gets fewer than 1024 bytes from its first call to the underlying 'read' routine and then tries to read more data to fulfill your whole request.

But that's mostly a guess and I'd've guessed that read wouldn't do that, but it fits your problem description.

- tye        

Replies are listed 'Best First'.
Re^2: Sockets + Read (sysread)
by Anonymous Monk on Aug 17, 2005 at 23:46 UTC
    sysread has the same result.

    I tried that before posting. Should have mentioned that.