/src/main/java/org/htmlunit/util/EncodingSniffer.java
bytes = readAndPrepend( SIZE_OF_HTML_CONTENT_SNIFFED, bytes) ;
bytes = readAndPrepend ( content, SIZE_OF_HTML_CONTENT_SNIFFED, bytes ) ;
} byte[] bytes = read(content, 3); encoding = sniffEncodingFromUnicodeBom(bytes); if (encoding != null) { return encoding; } <extra_id_0> encoding = sniffEncodingFromMetaTag(bytes); return encoding; } public static Charset sniffXmlEncoding(final List<NameValuePair> headers, final InputStream content) throws IOException { Charset encoding = sniffEncodingFromHttpHeaders(headers);