bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#12208: yes-or-no-p escapes with-current-buffer


From: martin rudalics
Subject: bug#12208: yes-or-no-p escapes with-current-buffer
Date: Mon, 27 Aug 2012 11:15:21 +0200

=== modified file 'src/window.c'
--- src/window.c    2012-08-18 06:06:39 +0000
+++ src/window.c    2012-08-18 13:09:15 +0000
@@ -5889,7 +5889,13 @@
     }

   if (!NILP (new_current_buffer))
-    Fset_buffer (new_current_buffer);
+    {
+      Fset_buffer (new_current_buffer);
+      /* If the new current buffer doesn't appear in the selected
+     window, go to its old point.  */
+ if (!EQ (XWINDOW (data->current_window)->buffer, new_current_buffer))
+    Fgoto_char (make_number (old_point));
+    }

   Vminibuf_scroll_window = data->minibuf_scroll_window;
   minibuf_selected_window = data->minibuf_selected_window;

Installed in revision 109789 on trunk.  Bug closed.

martin






reply via email to

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