]> git.eshelyaron.com Git - emacs.git/commitdiff
lisp/gnus/mail-source.el (mail-source-call-script): Pop up an error buffer if a mail...
authorTimo Lilja <timo.lilja@iki.fi>
Thu, 5 Feb 2015 07:52:15 +0000 (07:52 +0000)
committerKatsumi Yamaoka <yamaoka@jpl.org>
Thu, 5 Feb 2015 07:52:15 +0000 (07:52 +0000)
lisp/gnus/ChangeLog
lisp/gnus/mail-source.el

index 0616a9eaa88f3cca2283fc85ad082b96637a090f..19bf562cc232c9aaa30567a1c5e67bf0816fa4d3 100644 (file)
@@ -1,3 +1,8 @@
+2015-02-05  Timo Lilja  <timo.lilja@iki.fi>  (tiny change)
+
+       * mail-source.el (mail-source-call-script): If scripts exit with an
+       error, pop up an error buffer.
+
 2015-02-05  Lars Ingebrigtsen  <larsi@gnus.org>
 
        * gnus-sum.el (gnus-extra-headers): Add the popular Gmail X-GM-LABELS
index eb05d714aba42111f9af6ac0c2c26fa5b1f2fb1a..94c8950988d411bc51ee3a105eed3513931a2c2d 100644 (file)
@@ -750,13 +750,16 @@ Deleting old (> %s day(s)) incoming mail file `%s'." diff bfile)
       (setq script (substring script 0 (match-beginning 0))
            background 0))
     (setq result
-         (call-process shell-file-name nil background nil
+         (call-process shell-file-name nil stderr nil
                        shell-command-switch script))
-    (when (and result
-              (not (zerop result)))
-      (set-buffer stderr)
-      (message "Mail source error: %s" (buffer-string)))
-    (kill-buffer stderr)))
+    (if (and result
+             (not (zerop result)))
+        (progn
+          (split-window-vertically)
+          (other-window 1)
+          (switch-to-buffer stderr)
+          (message "Mail source error: %s " (buffer-string)))
+      (kill-buffer stderr))))
 
 ;;;
 ;;; Different fetchers