[mew-dist 18275] Re: mew-config-alistとMessage-id
Tatsuya Kinoshita
tats at example.com
2001年 7月 29日 (日) 02:50:57 JST
In message [mew-dist 18263], on Sat, 28 Jul 2001,
KIMURA Yasuhiro <yasu at example.com> wrote:
> mew-case-guess-when-composed t
> mew-case-guess-alist '(("From:"
> ("default.org" . "default")
> ("another.org" . "another"))))
> ええと、↑のように設定した場合はC-c C-mを実行した時点でFrom:行に基づき
> caseが自動的に設定されるのだと思っていたのですが、違うのでしょうか?
違いませんが、バグが潜んでいました。パッチをお試しください。
--
木下達也
-------------- next part --------------
This patch is written by Tatsuya Kinoshita. Copyright is disclaimed.
--- mew/mew-draft.el Mon Jul 9 00:21:57 2001
+++ mew-tats/mew-draft.el Sun Jul 29 02:43:36 2001
@@ -759,18 +759,23 @@
(defun mew-draft-process-message (action &optional privacy signer)
(let* ((buf (current-buffer))
- (case (mew-tinfo-get-case))
- (server (mew-smtp-server case))
- (ssh-server (mew-smtp-ssh-server case))
- (pnm (mew-smtp-info-name server ssh-server))
(old-case (mew-tinfo-get-case))
- sendit err)
+ (case old-case)
+ guessed-case server ssh-server pnm sendit err)
+ (when mew-case-guess-when-composed
+ (setq guessed-case (mew-draft-get-case-by-guess))
+ (when guessed-case
+ (if mew-case-guess-addition
+ (setq case (mew-draft-add-case (mew-tinfo-get-case) guessed-case))
+ (setq case guessed-case))))
+ (setq server (mew-smtp-server case))
+ (setq ssh-server (mew-smtp-ssh-server case))
+ (setq pnm (mew-smtp-info-name server ssh-server))
(if (mew-smtp-get-lock pnm)
(message "Another message is being sent. Try later.")
(run-hooks 'mew-send-hook)
- (if mew-case-guess-when-composed
- (mew-draft-set-case-by-guess))
- (unless (string= old-case (mew-tinfo-get-case))
+ (when guessed-case
+ (mew-tinfo-set-case case)
(mew-draft-replace-fields old-case)
(when (eq action 'send)
(mew-highlight-header)
Mew-dist メーリングリストの案内