HTML reader: Fix performance issue with malformed HTML tables.

We let a `</table>` tag close an open `<tr>` or `<td>`.
Closes #1167.
This commit is contained in:
John MacFarlane 2014-06-20 10:47:29 -07:00
parent cab4b829b3
commit b3b40546cb

View file

@ -471,6 +471,8 @@ pCloses tagtype = try $ do
(TagClose "ul") | tagtype == "li" -> return ()
(TagClose "ol") | tagtype == "li" -> return ()
(TagClose "dl") | tagtype == "li" -> return ()
(TagClose "table") | tagtype == "td" -> return ()
(TagClose "table") | tagtype == "tr" -> return ()
_ -> mzero
pTagText :: TagParser Inlines