> Has anyone come across a limit on the size of a transfer thru a Java socket?

Yes, I had this problem under Solaris. In my case packets greater than 1500
bytes was tryncated into 1500, most likely because of the ethernet packet size.
I submitted such behaviour to Javasoft in their Bug Parade section but they
said:

"DataInputStream.read does not guarantee that all len bytes are read. It returns
the number of bytes read and this may not be all len bytes. You may have to
either loop on a read until you get all the bytes or use readFully().".

Have a look at
http://developer.java.sun.com/developer/bugParade/bugs/4095603.html

The work around I use is simply the fragmentation of my 2Kb packet into two 1Kb
ones.

> This is NOT a problem on Windows-95 which I'd rather not use.

Thios didn't use to happen under Windows as well (as noted in my bug report) but
the point is that under any OS there is no guarantee about it... Too bad heh?

JVc.


----------------------------------------------------------------------
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to