2001-01-24 18:00:00 ShengHuo ZHU <zsh@cs.rochester.edu>
authorShengHuo ZHU <zsh@cs.rochester.edu>
Wed, 24 Jan 2001 23:55:54 +0000 (23:55 +0000)
committerShengHuo ZHU <zsh@cs.rochester.edu>
Wed, 24 Jan 2001 23:55:54 +0000 (23:55 +0000)
* rfc2047.el (rfc2047-encode): MIME charset is not coding system.
(rfc2047-charset-encoding-alist): Add big5.

lisp/ChangeLog
lisp/rfc2047.el

index 9c7172f..f783bb0 100644 (file)
@@ -1,3 +1,8 @@
+2001-01-24 18:00:00  ShengHuo ZHU  <zsh@cs.rochester.edu>
+
+       * rfc2047.el (rfc2047-encode): MIME charset is not coding system.
+       (rfc2047-charset-encoding-alist): Add big5.
+
 2001-01-24 17:00:00  ShengHuo ZHU  <zsh@cs.rochester.edu>
 
        * gnus-agent.el (gnus-agent-add-server): Redraw the line.
index d744b3d..3aa36fd 100644 (file)
@@ -73,6 +73,8 @@ The values can be:
     (iso-2022-jp . B)
     (iso-2022-kr . B)
     (gb2312 . B)
+    (big5 . B)
+    (cn-big5 . B)
     (cn-gb . B)
     (cn-gb-2312 . B)
     (euc-kr . B)
@@ -277,6 +279,7 @@ The buffer may be narrowed."
 (defun rfc2047-encode (b e charset)
   "Encode the word in the region B to E with CHARSET."
   (let* ((mime-charset (mm-mime-charset charset))
+        (cs (mm-charset-to-coding-system mime-charset))
         (encoding (or (cdr (assq mime-charset
                                  rfc2047-charset-encoding-alist))
                       'B))
@@ -294,8 +297,8 @@ The buffer may be narrowed."
          (unless (eobp)
            (insert "\n"))))
       (if (and (mm-multibyte-p)
-              (mm-coding-system-p mime-charset))
-         (mm-encode-coding-region (point-min) (point-max) mime-charset))
+              (mm-coding-system-p cs))
+         (mm-encode-coding-region (point-min) (point-max) cs))
       (funcall (cdr (assq encoding rfc2047-encoding-function-alist))
               (point-min) (point-max))
       (goto-char (point-min))