Escape quotes in HTML attributes #197

merged 1 commit into from Jan 5, 2014


None yet

2 participants

geekman commented Jan 5, 2014

Quotes in HTML attributes are not quoted, thereby causing the HTMLParser to ignore the remaining part of the document. This bug was found due to a Python-Markdown parsing bug I've filed here.

The bug only happens when more than one filter that uses HTMLParser is chained. The input HTML is <img ... title="&quot;title" /> and after one round of parsing it becomes <img ... title=""title" /> and this input to the next filter will result in (silent) truncation due to invalid HTML.

@posativ posativ merged commit 9e05d4f into posativ:master Jan 5, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment