* lisp/mail/emacsbug.el (report-emacs-bug-hook): Mailclient ignores From.
authorGlenn Morris <rgm@gnu.org>
Wed, 1 Jun 2011 03:35:49 +0000 (20:35 -0700)
committerGlenn Morris <rgm@gnu.org>
Wed, 1 Jun 2011 03:35:49 +0000 (20:35 -0700)
lisp/ChangeLog
lisp/mail/emacsbug.el

index 8f96a83..307aac7 100644 (file)
        (rcirc-decode-coding-system): Allow value nil for automatic coding
        system detection.
 
+2011-06-01  Glenn Morris  <rgm@gnu.org>
+
+       * mail/emacsbug.el (report-emacs-bug-hook): Mailclient ignores From.
+
 2011-05-29  Chong Yidong  <cyd@stupidchicken.com>
 
        * image.el (image-animate-max-time): Allow nil and t values.
index ce4dde2..b1b3c44 100644 (file)
@@ -331,6 +331,7 @@ usually do not have translators to read other languages for them.\n\n")
 
 ;; It's the default mail mode, so it seems OK to use its features.
 (autoload 'message-bogus-recipient-p "message")
+(defvar message-send-mail-function)
 
 (defun report-emacs-bug-hook ()
   "Do some checking before sending a bug report."
@@ -343,6 +344,10 @@ usually do not have translators to read other languages for them.\n\n")
                        report-emacs-bug-orig-text)
          (error "No text entered in bug report"))
     (or report-emacs-bug-no-confirmation
+       ;; mailclient.el does not handle From (at present).
+       (if (eq major-mode 'message-mode)
+           (eq message-send-mail-function 'message-send-mail-with-mailclient)
+         (eq send-mail-function 'mailclient-send-it))
        ;; Not narrowing to the headers, but that's OK.
        (let ((from (mail-fetch-field "From")))
          (and (or (not from)