]> granicus.if.org Git - neomutt/commitdiff
Exit with a nonzero value if sending a message in batch mode fails (bug #2709).
authorMichael Elkins <me@mutt.org>
Tue, 10 Apr 2007 03:36:27 +0000 (20:36 -0700)
committerMichael Elkins <me@mutt.org>
Tue, 10 Apr 2007 03:36:27 +0000 (20:36 -0700)
main.c

diff --git a/main.c b/main.c
index 66d771203ff4ac375f92d5f31fe510f33c10a7f4..e84ac8003eac2d6cca21d0376a5562ee59f05318 100644 (file)
--- a/main.c
+++ b/main.c
@@ -924,10 +924,13 @@ int main (int argc, char **argv)
       mutt_free_list (&attach);
     }
 
-    ci_send_message (sendflags, msg, tempfile, NULL, NULL);
+    int rv = ci_send_message (sendflags, msg, tempfile, NULL, NULL);
 
     if (!option (OPTNOCURSES))
       mutt_endwin (NULL);
+
+    if (rv)
+      exit(1);
   }
   else
   {