mirror of
https://github.com/internetarchive/heritrix3.git
synced 2026-09-26 15:46:31 +00:00
[HER-741] Make extractors interrogate for charset
* ExtractorHTML
fix reflexive probe to look as many characters in (1000) as initially
This commit is contained in:
@@ -672,7 +672,7 @@ public class ExtractorHTML extends ContentExtractor implements InitializingBean
|
||||
String contentPrefix = curi.getRecorder().getContentReplayPrefixString(1000);
|
||||
Charset contentDeclaredEncoding = getContentDeclaredCharset(curi,contentPrefix);
|
||||
if(!curi.getRecorder().getCharset().equals(contentDeclaredEncoding) && contentDeclaredEncoding!=null) {
|
||||
String newContentPrefix = curi.getRecorder().getContentReplayPrefixString(50,contentDeclaredEncoding);
|
||||
String newContentPrefix = curi.getRecorder().getContentReplayPrefixString(1000,contentDeclaredEncoding);
|
||||
Charset reflexiveCharset = getContentDeclaredCharset(curi, newContentPrefix);
|
||||
if(contentDeclaredEncoding.equals(reflexiveCharset)) {
|
||||
// content-declared charset is self-consistent; use
|
||||
|
||||
Reference in New Issue
Block a user