buf.mark(9000);
try {
BufferedReader r = new BufferedReader(new InputStreamReader(
buf));
CodePageParser p = new CodePageParser();
encoding = p.parseEncoding(r);
buf.reset();
in = new BufferedReader(new InputStreamReader(buf, encoding));
} catch (IOException e1) {
buf.reset();