I've been scratching my head over this for most of the afternoon:
One client talking to a server, both transport streams at both ends are wrapped in a java.io.Input/OutputStream, which in turn are wrapped in BufferedInput/OutputStream and then finally wrapped in a DataInput/OutputStream.
Both streams in both directions are set to blocking.
1. Client makes the connection to the server with no problem and easily makes it to the FilterAdapter.
2. Client sends ints and strings to the server - with the first object being an int
3. Observing the operation shows flushing happening at the correct places
4. Server hangs, waiting for the int ... however, 'available' says that there are 152 bytes available
5. Client times out after default period and breaks the connection
6. Server immediately reads in correctly all the data sitting in the buffer.
Sorcery. Any clues anyone, I'm baffled by this.
Cheers
Nick
_________________________________________________________________
With Windows Live, you can organise, edit, and share your photos.
http://clk.atdmt.com/UKM/go/134665338/direct/01/