This is the mail archive of the
java-patches@gcc.gnu.org
mailing list for the Java project.
StringBuffer patch
- From: Mark Wielaard <mark at klomp dot org>
- To: java-patches at gcc dot gnu dot org
- Date: 22 Dec 2002 22:04:30 +0100
- Subject: StringBuffer patch
- Organization:
Hi,
StringBuffer.getChars() could throw an Exception because it had a bogus
check of the destination offset against the number of characters in the
StringBuffer. This was already fixed in the Classpath version. So this
patch replaces getChars() with the version in Classpath. (There are a
couple of other changes in the Classpath version that are worth
investigating, but this change fixes a real nasty bug.)
2002-12-21 Mark Wielaard <mark@klomp.org>
* java/lang/StringBuffer.java (getChars): Remove wrong of dstOffset
against count.
There is now an extra test in Mauve for this case (which passes with
this patch). It also allowed me to get Eclipse running a bit more.
OK for branch and mainline?
Cheers,
Mark