diff options
author | Richard M. Stallman <[email protected]> | 2006-08-25 21:10:26 +0000 |
---|---|---|
committer | Richard M. Stallman <[email protected]> | 2006-08-25 21:10:26 +0000 |
commit | 611ac52147a4682f0c8befc8483dc095966d3fbf (patch) | |
tree | 7dbfe51c5ef579082d1791f5e45d628625e0e908 /src | |
parent | f9de7738112d70ce46ceded87bba3616c04553bb (diff) |
(Fswitch_to_buffer): Fix previous change.
Diffstat (limited to 'src')
-rw-r--r-- | src/buffer.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/src/buffer.c b/src/buffer.c index f6c45852b5..81ea51b357 100644 --- a/src/buffer.c +++ b/src/buffer.c @@ -1685,10 +1685,15 @@ the window-buffer correspondences. */) if (EQ (buffer, Fwindow_buffer (selected_window))) { - if (NILP (norecord) && !EQ (buffer, XCDR (XCAR (Vbuffer_alist)))) + /* Basically a NOP. Avoid signalling an error in the case where + the selected window is dedicated, or a minibuffer. */ + + /* But do put this buffer at the front of the buffer list, + unless that has been inhibited. Note that even if + BUFFER is at the front of the main buffer-list already, + we still want to move it to the front of the frame's buffer list. */ + if (NILP (norecord)) record_buffer (buffer); - /* Basically a NOP. Avoid signalling an error if the selected window - is dedicated, or a minibuffer, ... */ return Fset_buffer (buffer); } |