GNU bug report logs - #12502
24.2.50; Debugger messes up current-buffer

Previous Next

Package: emacs;

Reported by: Helmut Eller <eller.helmut <at> gmail.com>

Date: Mon, 24 Sep 2012 08:34:01 UTC

Severity: normal

Found in version 24.2.50

Done: martin rudalics <rudalics <at> gmx.at>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: martin rudalics <rudalics <at> gmx.at>
To: Helmut Eller <eller.helmut <at> gmail.com>
Cc: 12502 <at> debbugs.gnu.org
Subject: bug#12502: 24.2.50; Debugger messes up current-buffer
Date: Mon, 24 Sep 2012 14:38:01 +0200
[Message part 1 (text/plain, inline)]
> The debugger now changes the current buffer in the following situation:
[...]
> This is a regression to older versions.

Thanks for the report.  Would the attached patch fix it?

BTW, I notice that you quite often run functions with a current buffer
different from that of the selected window.  In all these cases
`quit-window' might misbehave for you because it does not restore the
buffer that was current at the time the window's buffer was displayed.
So if you see any problems in this context, please tell me.  We then
could try to restore the current buffer (optionally at least) too.

martin
[debug-restore-current-buffer.diff (text/plain, inline)]
=== modified file 'lisp/emacs-lisp/debug.el'
--- lisp/emacs-lisp/debug.el	2012-09-20 13:35:13 +0000
+++ lisp/emacs-lisp/debug.el	2012-09-24 12:30:50 +0000
@@ -273,7 +273,8 @@
 	    (setq debugger-previous-window-height
 		  (window-total-size debugger-window))
 	    ;; Unshow debugger-buffer.
-	    (quit-restore-window debugger-window debugger-bury-or-kill))
+	    (quit-restore-window debugger-window debugger-bury-or-kill)
+	    (set-buffer debugger-old-buffer))
           ;; Restore previous state of debugger-buffer in case we were
           ;; in a recursive invocation of the debugger, otherwise just
           ;; erase the buffer and put it into fundamental mode.



This bug report was last modified 12 years and 231 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.