From d9f82f6511f5e44c9d86785aefddb6f74baa014d Mon Sep 17 00:00:00 2001 From: ichikawa Date: Sun, 26 Nov 2000 08:44:48 +0000 Subject: [PATCH] * lisp/message.el (message-send-mail-with-smtp): Change error handling 'cause delete-process will return nil on most platform, then message-send-mail-with-smtp seems fail to send message even sending message success. --- lisp/message.el | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/lisp/message.el b/lisp/message.el index e10caf1..ee420ab 100644 --- a/lisp/message.el +++ b/lisp/message.el @@ -3070,13 +3070,19 @@ to find out how to use this." (run-hooks 'message-send-mail-hook) (if recipients (let ((result (static-if (fboundp 'smtp-send-buffer) - (smtp-send-buffer user-mail-address recipients - (current-buffer)) + (condition-case error + (progn + (smtp-send-buffer user-mail-address recipients + (current-buffer)) + t) + (error + (format "%d %s" + (car (cdr error)) (cdr (cdr error))))) (smtp-via-smtp user-mail-address recipients (current-buffer))))) (unless (eq result t) - (error "Sending failed; " result))) + (error "Sending failed; %s" result))) (error "Sending failed; no recipients")))) (defsubst message-maybe-split-and-send-news (method) -- 1.7.10.4