# HG changeset patch # User Katsumi Yamaoka # Date 1283321089 0 # Node ID f661002e9a6d7873df2dfd3d58e763edce9f88db # Parent fc3e98cf87b77bed9b4fcecc754b1127be7706b3 gnus-article-html: Decode contents by charset. diff -r fc3e98cf87b7 -r f661002e9a6d lisp/gnus/ChangeLog --- a/lisp/gnus/ChangeLog Wed Sep 01 04:48:51 2010 +0000 +++ b/lisp/gnus/ChangeLog Wed Sep 01 06:04:49 2010 +0000 @@ -1,3 +1,7 @@ +2010-09-01 Katsumi Yamaoka + + * gnus-html.el (gnus-article-html): Decode contents by charset. + 2010-09-01 Katsumi Yamaoka * gnus-html.el (gnus-html-cache-directory, gnus-html-cache-size) diff -r fc3e98cf87b7 -r f661002e9a6d lisp/gnus/gnus-html.el --- a/lisp/gnus/gnus-html.el Wed Sep 01 04:48:51 2010 +0000 +++ b/lisp/gnus/gnus-html.el Wed Sep 01 06:04:49 2010 +0000 @@ -66,7 +66,13 @@ (let* ((coding-system-for-read 'utf-8) (coding-system-for-write 'utf-8) (default-process-coding-system - (cons coding-system-for-read coding-system-for-write))) + (cons coding-system-for-read coding-system-for-write)) + (charset (mail-content-type-get (mm-handle-type handle) + 'charset))) + (when (and charset + (setq charset (mm-charset-to-coding-system charset)) + (not (eq charset 'ascii))) + (mm-decode-coding-region (point-min) (point-max) charset)) (call-process-region (point-min) (point-max) "w3m" nil article-buffer nil