bugs.java.com
Bug ID: JDK-6294060 Use of substring() causes memory leak
It's an error in java.lang.String source code which is the same for all JDK distributions. If the performance optimizations should still be used in furture documentation must be added to String class so users of substring will be warned at least. I have created a more simple example class...