removed unnecessary string=>utf8 byte[]=>input stream=>reader converts, utf8 helper added (UnsupportedEndodingException should not thrown)

This commit is contained in:
Honfika
2013-11-17 09:08:05 +01:00
parent 9a7016fe29
commit f0697ebeb6
64 changed files with 319 additions and 215 deletions
@@ -18,6 +18,7 @@ package com.jpexs.decompiler.flash.abc;
import com.jpexs.decompiler.flash.abc.types.*;
import com.jpexs.decompiler.flash.abc.types.traits.*;
import com.jpexs.helpers.utf8.Utf8Helper;
import java.io.ByteArrayOutputStream;
import java.io.IOException;
import java.io.InputStream;
@@ -368,7 +369,7 @@ public class ABCInputStream extends InputStream {
public String readString() throws IOException {
int length = readU30();
byte[] b = safeRead(length);
String r = new String(b, "UTF-8");
String r = new String(b, Utf8Helper.charset);
return r;
}