John Zigman spotted a typo in SocketChannelImpl.read() where we could
put too much bytes into the destination ByteBufffer. This fixes it as he
suggested.

2005-11-11  Mark Wielaard  <[EMAIL PROTECTED]>

    Reported by [EMAIL PROTECTED] as bug #24608.
    * gnu/java/nio/SocketChannelImpl.java (read): Put readBytes in
    destination ByteBuffer when it doesn't have an array instead of len
    bytes.

Committed,

Mark

diff -u -r1.27 SocketChannelImpl.java
--- gnu/java/nio/SocketChannelImpl.java 2 Jul 2005 20:32:13 -0000       1.27
+++ gnu/java/nio/SocketChannelImpl.java 11 Nov 2005 11:59:58 -0000
@@ -258,7 +258,7 @@
        }
       else
         {
-          dst.put (data, offset, len);
+          dst.put (data, offset, readBytes);
         }

     return readBytes;

Attachment: signature.asc
Description: This is a digitally signed message part

_______________________________________________
Classpath-patches mailing list
Classpath-patches@gnu.org
http://lists.gnu.org/mailman/listinfo/classpath-patches

Reply via email to