changeset 107393:a2823b84b7fb

(mm-charset-to-coding-system): Use coding-system-from-name if it is available. (bug#5647)
author Katsumi Yamaoka <yamaoka@jpl.org>
date Mon, 15 Mar 2010 01:38:28 +0000
parents a61767ff6672
children e4adbc6451e9 e58f63afd901
files lisp/gnus/ChangeLog lisp/gnus/mm-util.el
diffstat 2 files changed, 8 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/gnus/ChangeLog	Sun Mar 14 21:56:41 2010 +0000
+++ b/lisp/gnus/ChangeLog	Mon Mar 15 01:38:28 2010 +0000
@@ -1,3 +1,8 @@
+2010-03-15  Katsumi Yamaoka  <yamaoka@jpl.org>
+
+	* mm-util.el (mm-charset-to-coding-system): Use coding-system-from-name
+	if it is available.  (bug#5647)
+
 2010-02-26  Glenn Morris  <rgm@gnu.org>
 
 	* message.el (message-send-mail-function): Change the default, so that
--- a/lisp/gnus/mm-util.el	Sun Mar 14 21:56:41 2010 +0000
+++ b/lisp/gnus/mm-util.el	Mon Mar 15 01:38:28 2010 +0000
@@ -566,6 +566,9 @@
 ;;; 	 (eq charset (coding-system-get charset 'mime-charset))
 	 )
     charset)
+   ;; Use coding system Emacs knows.
+   ((and (fboundp 'coding-system-from-name)
+	 (coding-system-from-name charset)))
    ;; Eval expressions from `mm-charset-eval-alist'
    ((let* ((el (assq charset mm-charset-eval-alist))
 	   (cs (car el))