Bug 1688368 - Check mFeedChardet before feeding the detector. r=emk
Differential Revision: https://phabricator.services.mozilla.com/D102905
This commit is contained in:
@@ -646,7 +646,7 @@ static void HandleProcessingInstruction(void* aUserData,
|
||||
void nsHtml5StreamParser::FinalizeSniffingWithDetector(
|
||||
Span<const uint8_t> aFromSegment, uint32_t aCountToSniffingLimit,
|
||||
bool aEof) {
|
||||
if (mSniffingBuffer) {
|
||||
if (mFeedChardet && mSniffingBuffer) {
|
||||
FeedDetector(Span(mSniffingBuffer.get(), mSniffingLength), false);
|
||||
}
|
||||
if (mFeedChardet && !aFromSegment.IsEmpty()) {
|
||||
|
||||
Reference in New Issue
Block a user