re PR libgcj/30600 (gnu.gcj.convert.BytesToCharsetAdaptor calculates bad argument for java.nio.Buffer.limit(int))

2007-01-29  Kaloian Doganov  <kaloian@doganov.org>

	PR libgcj/30600:
	* gnu/gcj/convert/BytesToCharsetAdaptor.java (read): Fix call to
	'limit'.

From-SVN: r121329
This commit is contained in:
Kaloian Doganov 2007-01-30 02:46:54 +00:00 committed by Tom Tromey
parent 7bef57a0bd
commit 2828987879
3 changed files with 8 additions and 2 deletions

View File

@ -1,3 +1,9 @@
2007-01-29 Kaloian Doganov <kaloian@doganov.org>
PR libgcj/30600:
* gnu/gcj/convert/BytesToCharsetAdaptor.java (read): Fix call to
'limit'.
2007-01-29 Kyle Galloway <kgallowa@redhat.com>
* include/java-interp.h: Added _Jv_Frame class and its two

View File

@ -1,4 +1,4 @@
/* Copyright (C) 2005 Free Software Foundation
/* Copyright (C) 2005, 2007 Free Software Foundation
This file is part of libgcj.
@ -71,7 +71,7 @@ public class BytesToCharsetAdaptor extends BytesToUnicode
{
if (inBuf == null || ! inBuf.hasArray() || inBuf.array() != inbuffer)
inBuf = ByteBuffer.wrap(inbuffer);
inBuf.limit(inpos + inlength);
inBuf.limit(inlength);
inBuf.position(inpos);
CharBuffer outBuf = CharBuffer.wrap(outbuffer, outpos, count);