From: morioka Date: Fri, 24 Apr 1998 18:57:28 +0000 (+0000) Subject: (decode-mime-charset-string): Use 'decode-mime-charset-region. X-Git-Tag: emu-unify-199811302358~1 X-Git-Url: http://git.chise.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=20bf19d4d8865ac6cf22dd46f303255f5680e73e;p=elisp%2Fapel.git (decode-mime-charset-string): Use 'decode-mime-charset-region. --- diff --git a/emu-x20.el b/emu-x20.el index 0252bbd..1c06239 100644 --- a/emu-x20.el +++ b/emu-x20.el @@ -155,12 +155,19 @@ find-file-hooks, etc. (encode-coding-string string cs) string))) -(defsubst decode-mime-charset-string (string charset) +;; (defsubst decode-mime-charset-string (string charset) +;; "Decode the STRING as MIME CHARSET." +;; (let ((cs (mime-charset-to-coding-system charset))) +;; (if cs +;; (decode-coding-string string cs) +;; string))) +(defun decode-mime-charset-string (string charset) "Decode the STRING as MIME CHARSET." - (let ((cs (mime-charset-to-coding-system charset))) - (if cs - (decode-coding-string string cs) - string))) + (with-temp-buffer + (insert string) + (decode-mime-charset-region (point-min)(point-max) charset) + (buffer-string) + )) (defvar charsets-mime-charset-alist