diff options
author | Stefan Monnier <monnier@iro.umontreal.ca> | 2007-03-26 15:09:52 +0000 |
---|---|---|
committer | Stefan Monnier <monnier@iro.umontreal.ca> | 2007-03-26 15:09:52 +0000 |
commit | 084c41ca0af70ac085393b87b71f188bc0f53473 (patch) | |
tree | b47d1c2258cb9d789855138fae110de5e03d968a /lisp/replace.el | |
parent | 5ae48997963db855572955b5b0db54427782627a (diff) | |
download | emacs-084c41ca0af70ac085393b87b71f188bc0f53473.tar.gz |
(occur-next-error): *Occur* might not be displayed in the
selected frame. Reported by David Hansen <david.hansen@gmx.net>.
Diffstat (limited to 'lisp/replace.el')
-rw-r--r-- | lisp/replace.el | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lisp/replace.el b/lisp/replace.el index a42f4ff4b57..a8dfd043c72 100644 --- a/lisp/replace.el +++ b/lisp/replace.el @@ -844,7 +844,8 @@ Compatibility function for \\[next-error] invocations." #'next-single-property-change) "No more matches") ;; In case the *Occur* buffer is visible in a nonselected window. - (set-window-point (get-buffer-window (current-buffer)) (point)) + (let ((win (get-buffer-window (current-buffer) t))) + (if win (set-window-point win (point)))) (occur-mode-goto-occurrence))) (defface match |