mirror of
https://github.com/RGBCube/serenity
synced 2025-05-16 19:55:06 +00:00
LibWeb: Parse documents without DOCTYPE gracefully
Seems like SOMEONE forgot to put a <!DOCTYPE html> on serenityos.org.. No matter, now we can handle it in the new parser! :^)
This commit is contained in:
parent
422e00c806
commit
3ce1af27dc
1 changed files with 5 additions and 1 deletions
|
@ -142,7 +142,11 @@ void HTMLDocumentParser::handle_initial(HTMLToken& token)
|
|||
m_insertion_mode = InsertionMode::BeforeHTML;
|
||||
return;
|
||||
}
|
||||
ASSERT_NOT_REACHED();
|
||||
|
||||
PARSE_ERROR();
|
||||
document().set_quirks_mode(true);
|
||||
m_insertion_mode = InsertionMode::BeforeHTML;
|
||||
process_using_the_rules_for(InsertionMode::BeforeHTML, token);
|
||||
}
|
||||
|
||||
void HTMLDocumentParser::handle_before_html(HTMLToken& token)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue