From: morioka Date: Tue, 9 Jun 1998 06:19:13 +0000 (+0000) Subject: (mime-edit-translate-single-part-tag): Add new argument `boundary'. X-Git-Tag: semi-1_5_4~5 X-Git-Url: http://git.chise.org/gitweb/?a=commitdiff_plain;h=7e741f1d7375a742aaabc0017b107f129fee7e45;p=elisp%2Fsemi.git (mime-edit-translate-single-part-tag): Add new argument `boundary'. (mime-edit-translate-region): Modify for `mime-edit-translate-single-part-tag'. --- diff --git a/mime-edit.el b/mime-edit.el index e3e32e1..fef7f76 100644 --- a/mime-edit.el +++ b/mime-edit.el @@ -1903,17 +1903,15 @@ Content-Transfer-Encoding: 7bit (insert encoding))) )))) -(defun mime-edit-translate-single-part-tag (&optional prefix) +(defun mime-edit-translate-single-part-tag (boundary &optional prefix) "Translate single-part-tag to MIME header." (if (re-search-forward mime-edit-single-part-tag-regexp nil t) (let* ((beg (match-beginning 0)) (end (match-end 0)) - (tag (buffer-substring beg end)) - ) + (tag (buffer-substring beg end))) (delete-region beg end) (let ((contype (mime-edit-get-contype tag)) - (encoding (mime-edit-get-encoding tag)) - ) + (encoding (mime-edit-get-encoding tag))) (insert (concat prefix "--" boundary "\n")) (save-restriction (narrow-to-region (point)(point)) @@ -1958,9 +1956,8 @@ Content-Transfer-Encoding: 7bit (t ;; It's a multipart message. (goto-char (point-min)) - (and (mime-edit-translate-single-part-tag) - (while (mime-edit-translate-single-part-tag "\n")) - ) + (and (mime-edit-translate-single-part-tag boundary) + (while (mime-edit-translate-single-part-tag boundary "\n"))) ;; Define Content-Type as "multipart/mixed". (setq contype (concat "multipart/mixed;\n boundary=\"" boundary "\""))