emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] master 24811ee 027/187: Show full backtraces if `async-debug' is


From: Michael Albinus
Subject: [elpa] master 24811ee 027/187: Show full backtraces if `async-debug' is non-nil
Date: Wed, 30 Dec 2015 11:49:29 +0000

branch: master
commit 24811ee757301b782d30457c5015db482d0e1897
Author: John Wiegley <address@hidden>
Commit: John Wiegley <address@hidden>

    Show full backtraces if `async-debug' is non-nil
---
 async.el |   15 ++++++++++-----
 1 files changed, 10 insertions(+), 5 deletions(-)

diff --git a/async.el b/async.el
index 11ee5c2..e951b69 100644
--- a/async.el
+++ b/async.el
@@ -139,14 +139,19 @@ as follows:
 
 (defun async-batch-invoke ()
   "Called from the child Emacs process' command-line."
-  (setq async-in-child-emacs t)
-  (condition-case err
+  (setq async-in-child-emacs t
+        debug-on-error async-debug)
+  (if debug-on-error
       (prin1 (funcall
               (async--receive-sexp (unless async-send-over-pipe
                                      command-line-args-left))))
-    (error
-     (backtrace)
-     (prin1 `(async-signal . ,err)))))
+    (condition-case err
+        (prin1 (funcall
+                (async--receive-sexp (unless async-send-over-pipe
+                                       command-line-args-left))))
+      (error
+       (backtrace)
+       (prin1 `(async-signal . ,err))))))
 
 (defun async-ready (future)
   "Query a FUTURE to see if the ready is ready -- i.e., if no blocking



reply via email to

[Prev in Thread] Current Thread [Next in Thread]