diff options
| author | Martin Rudalics | 2011-11-23 10:57:27 +0100 |
|---|---|---|
| committer | Martin Rudalics | 2011-11-23 10:57:27 +0100 |
| commit | 56e2e794b0b830b2ccb8d43f5651d13f8be176a5 (patch) | |
| tree | d09ca82f4787e9043ba41882f159d90c9e47557a | |
| parent | da94eca12f45cc4d22f3a7f6febfd94b87359bbe (diff) | |
| download | emacs-56e2e794b0b830b2ccb8d43f5651d13f8be176a5.tar.gz emacs-56e2e794b0b830b2ccb8d43f5651d13f8be176a5.zip | |
In Fkill_buffer do replace_buffer_in_windows before Fset_buffer. (Bug#10114)
* buffer.c (Fkill_buffer): Run replace_buffer_in_windows before
making another buffer current. (Bug#10114)
| -rw-r--r-- | src/ChangeLog | 5 | ||||
| -rw-r--r-- | src/buffer.c | 9 |
2 files changed, 12 insertions, 2 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index ade7eaec1e0..694478e2d39 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,3 +1,8 @@ | |||
| 1 | 2011-11-23 Martin Rudalics <rudalics@gmx.at> | ||
| 2 | |||
| 3 | * buffer.c (Fkill_buffer): Run replace_buffer_in_windows before | ||
| 4 | making another buffer current. (Bug#10114) | ||
| 5 | |||
| 1 | 2011-11-23 Glenn Morris <rgm@gnu.org> | 6 | 2011-11-23 Glenn Morris <rgm@gnu.org> |
| 2 | 7 | ||
| 3 | * font.c (font_find_for_lface) [HAVE_NS]: Ignore case. (Bug#2526) | 8 | * font.c (font_find_for_lface) [HAVE_NS]: Ignore case. (Bug#2526) |
diff --git a/src/buffer.c b/src/buffer.c index a327a1650f1..f8482c351c5 100644 --- a/src/buffer.c +++ b/src/buffer.c | |||
| @@ -1526,7 +1526,13 @@ with SIGHUP. */) | |||
| 1526 | UNGCPRO; | 1526 | UNGCPRO; |
| 1527 | } | 1527 | } |
| 1528 | 1528 | ||
| 1529 | /* Make this buffer not be current. | 1529 | /* Run replace_buffer_in_windows before making another buffer current |
| 1530 | since set-window-buffer-start-and-point will refuse to make another | ||
| 1531 | buffer current if the selected window does not show the current | ||
| 1532 | buffer. (Bug#10114) */ | ||
| 1533 | replace_buffer_in_windows (buffer); | ||
| 1534 | |||
| 1535 | /* Make this buffer not be current. | ||
| 1530 | In the process, notice if this is the sole visible buffer | 1536 | In the process, notice if this is the sole visible buffer |
| 1531 | and give up if so. */ | 1537 | and give up if so. */ |
| 1532 | if (b == current_buffer) | 1538 | if (b == current_buffer) |
| @@ -1566,7 +1572,6 @@ with SIGHUP. */) | |||
| 1566 | 1572 | ||
| 1567 | /* These may run Lisp code and into infinite loops (if someone | 1573 | /* These may run Lisp code and into infinite loops (if someone |
| 1568 | insisted on circular lists) so allow quitting here. */ | 1574 | insisted on circular lists) so allow quitting here. */ |
| 1569 | replace_buffer_in_windows (buffer); | ||
| 1570 | frames_discard_buffer (buffer); | 1575 | frames_discard_buffer (buffer); |
| 1571 | 1576 | ||
| 1572 | clear_charpos_cache (b); | 1577 | clear_charpos_cache (b); |