From e48ca9b41d4df24ee4f5efedc91d22db8cf827d4 Mon Sep 17 00:00:00 2001 From: morioka Date: Thu, 27 Nov 1997 08:54:59 +0000 Subject: [PATCH] (message-do-fcc): Guard `coding-system-for-write' by `raw-text'; run `message-before-do-fcc-hook'. --- lisp/message.el | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/lisp/message.el b/lisp/message.el index e549b51..3830830 100644 --- a/lisp/message.el +++ b/lisp/message.el @@ -32,7 +32,9 @@ (eval-when-compile (require 'cl)) (require 'mailheader) -(require 'rmail) +(condition-case nil + (require 'rmail) + (t (message "Ignore any errors about rmail from this file"))) (require 'nnheader) (require 'timezone) (require 'easymenu) @@ -2419,6 +2421,7 @@ to find out how to use this." "Process Fcc headers in the current buffer." (let ((case-fold-search t) (buf (current-buffer)) + (coding-system-for-write 'raw-text) list file) (save-excursion (set-buffer (get-buffer-create " *message temp*")) @@ -2430,6 +2433,7 @@ to find out how to use this." (while (setq file (message-fetch-field "fcc")) (push file list) (message-remove-header "fcc" nil t))) + (run-hooks 'message-before-do-fcc-hook) (goto-char (point-min)) (re-search-forward (concat "^" (regexp-quote mail-header-separator) "$")) (replace-match "" t t) @@ -2563,11 +2567,10 @@ to find out how to use this." (defun message-make-organization () "Make an Organization header." (let* ((organization - (or (getenv "ORGANIZATION") - (when message-user-organization + (when message-user-organization (if (message-functionp message-user-organization) (funcall message-user-organization) - message-user-organization))))) + message-user-organization)))) (save-excursion (message-set-work-buffer) (cond ((stringp organization) @@ -3176,7 +3179,10 @@ Headers already prepared in the buffer are not modified." (unless follow-to (if (or (not wide) to-address) - (setq follow-to (list (cons 'To (or to-address reply-to from)))) + (progn + (setq follow-to (list (cons 'To (or to-address reply-to from)))) + (when (and wide mct) + (push (cons 'Cc mct) follow-to))) (let (ccalist) (save-excursion (message-set-work-buffer) -- 1.7.10.4