X-Git-Url: http://git.hcoop.net/bpt/emacs.git/blobdiff_plain/0f6990a78ae5016d8ae73253cdb4739adf0197e7..5396468298b0122469e0b41da8f49860d99a2b51:/lisp/mail/feedmail.el diff --git a/lisp/mail/feedmail.el b/lisp/mail/feedmail.el index 934637ecbb..eaac5c17cd 100644 --- a/lisp/mail/feedmail.el +++ b/lisp/mail/feedmail.el @@ -83,7 +83,7 @@ ;; work properly. If you don't know what custom is all about and want ;; to edit your user option elisp variables the old fashioned way, ;; just imagine that all the "defcustom" stuff you see below is really -;; "defvar", and ignore everthing else. For info about custom, see +;; "defvar", and ignore everything else. For info about custom, see ;; . ;; ;; This code does in elisp a superset of the stuff that used to be done @@ -336,7 +336,7 @@ ;; for FQM files if you're a VM user ;; change buffer-substring calls to buffer-substring-no-properties for ;; speed-up (suggested by Howard Melman ) -;; feedmail-sendmail-f-doesnt-sell-me-out to contol "-f" in call to sendmail +;; feedmail-sendmail-f-doesnt-sell-me-out to control "-f" in call to sendmail ;; in feedmail-buffer-to-sendmail ;; better trapping of odd conditions during the running of the queue; ;; thanks to Yigal Hochberg for helping me test much of this by remote @@ -351,7 +351,7 @@ ;; systems with non-classic /bin/[r]mail behavior ;; guard against nil user-mail-address in generating MESSAGE-ID: ;; feedmail-queue-slug-suspect-regexp is now a variable to -;; accomodate non-ASCII environments (thanks to +;; accommodate non-ASCII environments (thanks to ;; Makoto.Nakagawa@jp.compaq.com for this suggestion) ;; feedmail-buffer-to-smtp, to parallel feedmail-buffer-to-smtpmail ;; patchlevel 10, 22 April 2001 @@ -1356,7 +1356,7 @@ for you. Add this function to `mail-send-hook' with something like this: (add-hook 'mail-send-hook 'feedmail-mail-send-hook-splitter) Then add the functions you want called to either `feedmail-mail-send-hook-queued' -or `feedmail-mail-send-hook', as apprpriate. The distinction is that +or `feedmail-mail-send-hook', as appropriate. The distinction is that `feedmail-mail-send-hook' will be called when you send mail from a composition buffer (typically by typing C-c C-c), whether the message is sent immediately or placed in the queue or drafts directory. `feedmail-mail-send-hook-queued' is @@ -1633,22 +1633,21 @@ local gurus." ;; no evil. (feedmail-say-debug ">in-> feedmail-buffer-to-smtpmail %s" addr-listoid) (require 'smtpmail) - (if (not (smtpmail-via-smtp addr-listoid prepped)) - (progn - (set-buffer errors-to) - (insert "Send via smtpmail failed. Probable SMTP protocol error.\n") - (insert "Look for details below or in the *Messages* buffer.\n\n") - (let ((case-fold-search t) - ;; don't be overconfident about the name of the trace buffer - (tracer (concat "trace.*smtp.*" (regexp-quote smtpmail-smtp-server)))) - (mapcar - (lambda (buffy) - (if (string-match tracer (buffer-name buffy)) - (progn - (insert "SMTP Trace from " (buffer-name buffy) "\n---------------") - (insert-buffer-substring buffy) - (insert "\n\n")))) - (buffer-list)))))) + (let ((result (smtpmail-via-smtp addr-listoid prepped))) + (when result + (set-buffer errors-to) + (insert "Send via smtpmail failed: %s" result) + (let ((case-fold-search t) + ;; don't be overconfident about the name of the trace buffer + (tracer (concat "trace.*smtp.*" (regexp-quote smtpmail-smtp-server)))) + (mapcar + (lambda (buffy) + (if (string-match tracer (buffer-name buffy)) + (progn + (insert "SMTP Trace from " (buffer-name buffy) "\n---------------") + (insert-buffer-substring buffy) + (insert "\n\n")))) + (buffer-list)))))) (declare-function smtp-via-smtp "ext:smtp" (sender recipients smtp-text-buffer)) (defvar smtp-server) @@ -2189,7 +2188,7 @@ you can set `feedmail-queue-reminder-alist' to nil." (if (or (eq user-sez ?\C-m) (eq user-sez ?\C-j) (eq user-sez ?y)) (setq user-sez d-char)) ;; these char-to-int things are because of some - ;; incomprensible difference between the two in + ;; incomprehensible difference between the two in ;; byte-compiled stuff between Emacs and XEmacs ;; (well, I'm sure someone could comprehend it, ;; but I say 'uncle') @@ -2411,7 +2410,7 @@ mapped to mostly alphanumerics for safety." (a-re-dtcb "^\\(To\\|Cc\\|Bcc\\):") (a-re-dtc "^\\(To\\|Cc\\):") (a-re-db "^Bcc:") - ;; to get a temporary changable copy + ;; to get a temporary changeable copy (mail-header-separator mail-header-separator) ) (unwind-protect