Subject: bug#12502: closed (Re: bug#12502: 24.2.50; Debugger messes up current-buffer)

From: [email-masked] (GNU bug Tracking System)
Date: Wed, 03 Oct 2012 09:16:02 +0000

Your bug report

#12502: 24.2.50; Debugger messes up current-buffer

which was filed against the emacs package, has been closed.

The explanation is attached below, along with your original report.
If you require more details, please reply to [email-masked].

-- 
12502: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=12502
GNU Bug Tracking System
Contact [email-masked] with problems

Subject: Re: bug#12502: 24.2.50; Debugger messes up current-buffer
From: martin rudalics <[email-masked]>
To: Helmut Eller <[email-masked]>
Cc: [email-masked]
Date: Wed, 03 Oct 2012 11:14:55 +0200
List-Id: <debbugs-submit.debbugs.gnu.org>

 >> Thanks for the report.  Would the attached patch fix it?
 >
 > Yes, that seems to fix the problem.

Installed.  Bug closed.

 > But the save-exursion in line 218
 > looks now supsisously irrelevant.

I left it in because IIUC it can't do any harm.

martin

Subject: 24.2.50; Debugger messes up current-buffer
From: Helmut Eller <[email-masked]>
To: [email-masked]
Date: Mon, 24 Sep 2012 10:31:04 +0200
List-Id: <debbugs-submit.debbugs.gnu.org>

The debugger now changes the current buffer in the following situation:

1. Create a file foo.el with this code:

(progn
  (require 'cl)
  (defun foo ()
    (with-current-buffer (get-buffer-create "test")
      (let ((b (current-buffer)))
	(debug)
	(assert (eq b (current-buffer)) t))))
  (foo))

2. In the foo.el buffer, evaluate the expression with C-x C-e

3. The debugger pops up with this message:
   Debugger entered: nil

4. Press c (i.e. debugger-continue)

5. The assertion fails with:
  Assertion failed: (eq b (current-buffer)), #<buffer test>, #<buffer foo.el>

This is a regression to older versions.

In GNU Emacs 24.2.50.1 (i686-pc-linux-gnu, GTK+ Version 2.20.1)
 of 2012-09-22 on ix
Bzr revision: 110128 [email-masked]
Windowing system distributor `The X.Org Foundation', version 11.0.10707000
Configured using:
 `configure '--with-jpeg=no' '--with-gif=no' '--with-tiff=no''