changeset 102277:ac468e2eb03e

Tobias C. Rittweiler <tcr at freebits.de> (tiny change) (sendmail-send-it): `call-process-region' can return a string. (Bug#2428)
author Glenn Morris <rgm@gnu.org>
date Thu, 26 Feb 2009 03:53:15 +0000
parents b8be61499474
children 527143cc2cfe
files lisp/mail/sendmail.el
diffstat 1 files changed, 7 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/mail/sendmail.el	Thu Feb 26 03:52:06 2009 +0000
+++ b/lisp/mail/sendmail.el	Thu Feb 26 03:53:15 2009 +0000
@@ -1168,8 +1168,13 @@
 			      )
 		      )
 		     (exit-value (apply 'call-process-region args)))
-		(or (null exit-value) (eq 0 exit-value)
-		    (error "Sending...failed with exit value %d" exit-value)))
+		(cond ((or (null exit-value) (eq 0 exit-value)))
+		      ((numberp exit-value)
+		       (error "Sending...failed with exit value %d" exit-value))
+		      ((stringp exit-value)
+		       (error "Sending...terminated by signal: %s" exit-value))
+		      (t
+		       (error "SENDMAIL-SEND-IT -- fall through: %S" exit-value))))
 	    (or fcc-was-found
 		(error "No recipients")))
 	  (if mail-interactive