HHH-7066 optimize for a special but not unlikely case

This commit is contained in:
Sanne Grinovero 2012-02-13 19:17:27 +00:00
parent 18185e58f0
commit 2710576f45
1 changed files with 3 additions and 0 deletions

View File

@ -109,6 +109,9 @@ public class DataHelper {
* @return The content as string
*/
private static String extractString(Reader characterStream, long start, int length) {
if ( length == 0 ) {
return "";
}
StringBuilder stringBuilder = new StringBuilder( length );
try {
long skipped = characterStream.skip( start );