From: hmurata Date: Mon, 12 Jun 2006 15:10:02 +0000 (+0000) Subject: * mel-b-ccl.el (base64-ccl-insert-encoded-file): Use X-Git-Tag: flim-1_14_9-pre0~14 X-Git-Url: http://git.chise.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c9bb0e1a7a1dc590c55780b5956d839db4ebcc0f;p=elisp%2Fflim.git * mel-b-ccl.el (base64-ccl-insert-encoded-file): Use `insert-file-contents-as-binary' instead of `insert-file-contents'. * mel-q-ccl.el (quoted-printable-ccl-insert-encoded-file): Likewise. --- diff --git a/ChangeLog b/ChangeLog index 4265f55..2431a22 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2006-06-12 Hiroya Murata + + * mel-b-ccl.el (base64-ccl-insert-encoded-file): Use + `insert-file-contents-as-binary' instead of `insert-file-contents'. + + * mel-q-ccl.el (quoted-printable-ccl-insert-encoded-file): + Likewise. + 2006-02-18 Hiroya Murata * smtp.el (smtp-debug): New user option. diff --git a/mel-b-ccl.el b/mel-b-ccl.el index 4a82772..69e178b 100644 --- a/mel-b-ccl.el +++ b/mel-b-ccl.el @@ -419,9 +419,13 @@ abcdefghijklmnopqrstuvwxyz\ (defun base64-ccl-insert-encoded-file (filename) "Encode contents of file FILENAME to base64, and insert the result." (interactive "*fInsert encoded file: ") - (let ((coding-system-for-read 'mel-ccl-base64-lf-rev) - format-alist) - (insert-file-contents filename))) + (insert + (decode-coding-string + (with-temp-buffer + (set-buffer-multibyte nil) + (insert-file-contents-as-binary filename) + (buffer-string)) + 'mel-ccl-base64-lf-rev))) (mel-define-method-function (mime-encode-string string (nil "base64")) 'base64-ccl-encode-string) diff --git a/mel-q-ccl.el b/mel-q-ccl.el index 3769fb9..cccacd8 100644 --- a/mel-q-ccl.el +++ b/mel-q-ccl.el @@ -898,9 +898,13 @@ abcdefghijklmnopqrstuvwxyz\ (defun quoted-printable-ccl-insert-encoded-file (filename) "Encode contents of the file named as FILENAME, and insert it." (interactive "*fInsert encoded file: ") - (let ((coding-system-for-read 'mel-ccl-quoted-printable-lf-lf-rev) - format-alist) - (insert-file-contents filename))) + (insert + (decode-coding-string + (with-temp-buffer + (set-buffer-multibyte nil) + (insert-file-contents-as-binary filename) + (buffer-string)) + 'mel-ccl-quoted-printable-lf-lf-rev))) (mel-define-method-function (mime-encode-string string (nil "quoted-printable"))