changeset 7917:7967c371644f

(mail-send-hook): Add defvar. (mail-send): Run mail-send-hook before the `Sending...' message.
author Richard M. Stallman <rms@gnu.org>
date Wed, 15 Jun 1994 22:16:04 +0000
parents 50e9e0c8806a
children 4561618ebf64
files lisp/mail/sendmail.el
diffstat 1 files changed, 4 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/mail/sendmail.el	Wed Jun 15 20:15:59 1994 +0000
+++ b/lisp/mail/sendmail.el	Wed Jun 15 22:16:04 1994 +0000
@@ -154,6 +154,9 @@
      (setq mail-mode-syntax-table (copy-syntax-table text-mode-syntax-table))
      (modify-syntax-entry ?% ". " mail-mode-syntax-table)))
 
+(defvar mail-send-hook nil
+  "Normal hook run before sending mail, in Mail mode.")
+
 (defun mail-setup (to subject in-reply-to cc replybuffer actions)
   (if (eq mail-aliases t)
       (progn
@@ -353,8 +356,8 @@
 	(or (buffer-modified-p)
 	    (y-or-n-p "Message already sent; resend? ")))
       (progn
+	(run-hooks 'mail-send-hook)
 	(message "Sending...")
-	(run-hooks 'mail-send-hook)
 	(funcall send-mail-function)
 	;; Now perform actions on successful sending.
 	(while mail-send-actions