[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: w3m-detect-meta-charset considering html comments
- From: Katsumi Yamaoka <yamaoka@xxxxxxx>
- Date: Mon, 04 Dec 2017 07:50:53 +0900
- X-ml-name: emacs-w3m
- X-mail-count: 12829
- References: <87indqv55w.fsf@gmail.com>
In [emacs-w3m:12828]
On Fri, 01 Dec 2017 13:28:27 -0200, Renato Ferreira wrote:
> Debugging a coding issue on a page i found that following:
> On (w3m-decode-buffer) when there is no content-charset defined by
> headers, it calls (w3m-detect-meta-charset). But that ends up detecting
> commented meta tags such as :
> <!--<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />-->
> Setting the wrong charset on the content.
> I corrected the issue through:
> (advice-add #'w3m-detect-meta-charset :before #'w3m-remove-comments)
> Please add (w3m-remove-comments) where you see most properly (such as
> w3m-detect-meta-charset or w3m-decode-buffer).
I've installed a fix in CVS. Thank you for pointing it out.