emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] master ef9f5c6 2/2: Protect *Backtrace* from being killed


From: Noam Postavsky
Subject: [Emacs-diffs] master ef9f5c6 2/2: Protect *Backtrace* from being killed (Bug#26650)
Date: Tue, 23 May 2017 20:11:51 -0400 (EDT)

branch: master
commit ef9f5c672a8e248dd7bd682101c03feb2e527340
Author: Noam Postavsky <address@hidden>
Commit: Noam Postavsky <address@hidden>

    Protect *Backtrace* from being killed (Bug#26650)
    
    * lisp/emacs-lisp/debug.el (debugger-mode): Call `top-level' in
    `kill-buffer-hook'.
---
 lisp/emacs-lisp/debug.el | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/lisp/emacs-lisp/debug.el b/lisp/emacs-lisp/debug.el
index cb77148..83456fc 100644
--- a/lisp/emacs-lisp/debug.el
+++ b/lisp/emacs-lisp/debug.el
@@ -727,6 +727,9 @@ Complete list of commands:
 \\{debugger-mode-map}"
   (setq truncate-lines t)
   (set-syntax-table emacs-lisp-mode-syntax-table)
+  (add-hook 'kill-buffer-hook
+            (lambda () (if (> (recursion-depth) 0) (top-level)))
+            nil t)
   (use-local-map debugger-mode-map))
 
 (defcustom debugger-record-buffer "*Debugger-record*"



reply via email to

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