Path: utzoo!utgpu!watmath!uunet!tut.cis.ohio-state.edu!UUNET.UU.NET!talos!kjones From: talos!kjones@UUNET.UU.NET (Kyle Jones) Newsgroups: gnu.emacs.bug Subject: set-window-point bug Message-ID: <8906081806.AA20018@talos.uucp> Date: 8 Jun 89 18:06:11 GMT Sender: daemon@tut.cis.ohio-state.edu Reply-To: kyle@cs.odu.edu Distribution: gnu Organization: GNUs Not Usenet Lines: 23 GNU Emacs 18.52.0 of Thu Apr 6 1989 on pm700 (berkeley-unix) In src/window.c DEFUN ("set-window-point", Fset_window_point, Sset_window_point, 2, 2, 0, "Make point value in WINDOW be at position POS in WINDOW's buffer.") (window, pos) Lisp_Object window, pos; { register struct window *w = decode_window (window); CHECK_NUMBER_COERCE_MARKER (pos, 1); if (w == XWINDOW (selected_window)) Fgoto_char (pos); else Fset_marker (w->pointm, pos, w->buffer); return pos; } The function's use of Fgoto_char(pos) changes the value of point in the wrong buffer if the current buffer is not the same buffer as that of the selected window, i.e. (not (eq (window-buffer (selected-window)) (current-buffer)))