From 63c974c5af66ca372ecf46799649e1e2b8a85c0f Mon Sep 17 00:00:00 2001 From: dec05eba Date: Mon, 19 Oct 2020 03:29:08 +0200 Subject: Take into consideration < /html> and
--- src/HtmlParser.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src') diff --git a/src/HtmlParser.c b/src/HtmlParser.c index 861168e..f01a3af 100644 --- a/src/HtmlParser.c +++ b/src/HtmlParser.c @@ -323,6 +323,7 @@ static void html_parser_parse_tag_start(HtmlParser *self) { } return; } else if(c == '/') { + html_parser_skip_whitespace(self); if(html_parser_peek_char(self) == '>') { html_parser_advance_char(self); if(tag_name_found) { @@ -457,6 +458,7 @@ void html_parser_parse(HtmlParser *self) { for(;;) { char c = html_parser_next_char(self); if(c == '<') { + html_parser_skip_whitespace(self); if(html_parser_peek_char(self) == '/') { html_parser_advance_char(self); html_parser_parse_tag_end(self); -- cgit v1.2.3