]> git.eshelyaron.com Git - emacs.git/commitdiff
xref--show-pos-in-buf: Don't set other-window-scroll-buffer
authorDmitry Gutov <dgutov@yandex.ru>
Sat, 2 Jan 2021 18:50:22 +0000 (20:50 +0200)
committerDmitry Gutov <dgutov@yandex.ru>
Sat, 2 Jan 2021 18:52:31 +0000 (20:52 +0200)
* lisp/progmodes/xref.el (xref--show-pos-in-buf):
Don't set other-window-scroll-buffer (bug#45581).

lisp/progmodes/xref.el

index 29e7b6849fd0e2b731c0df521a00cf18ed2d4ffc..d2b5acd55513f9e193ab759215ca532dcf912a49 100644 (file)
@@ -547,8 +547,7 @@ If SELECT is non-nil, select the target window."
   "Goto and display position POS of buffer BUF in a window.
 Honor `xref--original-window-intent', run `xref-after-jump-hook'
 and finally return the window."
-  (let* ((xref-buf (current-buffer))
-         (pop-up-frames
+  (let* ((pop-up-frames
           (or (eq xref--original-window-intent 'frame)
               pop-up-frames))
          (action
@@ -566,9 +565,6 @@ and finally return the window."
     (with-selected-window (display-buffer buf action)
       (xref--goto-char pos)
       (run-hooks 'xref-after-jump-hook)
-      (let ((buf (current-buffer)))
-        (with-current-buffer xref-buf
-          (setq-local other-window-scroll-buffer buf)))
       (selected-window))))
 
 (defun xref--display-buffer-in-other-window (buffer alist)