]> git.eshelyaron.com Git - emacs.git/commitdiff
From_ Johan Bockgrd, <http://article.gmane.org/gmane.emacs.devel/81056>
authorKatsumi Yamaoka <yamaoka@jpl.org>
Thu, 18 Oct 2007 22:49:05 +0000 (22:49 +0000)
committerKatsumi Yamaoka <yamaoka@jpl.org>
Thu, 18 Oct 2007 22:49:05 +0000 (22:49 +0000)
* net/tramp.el (tramp-rfn-eshadow-update-overlay): Save excursion.
Use `save-restriction' rather than `widen'.

lisp/ChangeLog
lisp/net/tramp.el

index eabf820754cde5a348f11bc6d3e77ec46cd25233..d4363b038186d7ef6e83932feb1bedf2ec030bfc 100644 (file)
@@ -1,3 +1,8 @@
+2007-10-18  Johan Bockg\e,Ae\e(Brd  <bojohan@gnu.org>
+
+       * net/tramp.el (tramp-rfn-eshadow-update-overlay): Save excursion.
+       Use `save-restriction' rather than `widen'.
+
 2007-10-18  Richard Stallman  <rms@gnu.org>
 
        * time.el (display-time-world-time-format): Display day # not month #.
index c8b2a72aad0fb847e2597ca0b77500d088d1b68e..0af9c457995ffa08c7b6c6ea7e1fcc87d1bcba0f 100644 (file)
@@ -2092,12 +2092,13 @@ been set up by `rfn-eshadow-setup-minibuffer'."
                          (symbol-value 'rfn-eshadow-overlay))
                 (funcall (symbol-function 'minibuffer-prompt-end)))))
     (when (file-remote-p (buffer-substring-no-properties end (point-max)))
-      (narrow-to-region
-       (1+ (or (string-match "/" (buffer-string) end) end)) (point-max))
-      (let ((rfn-eshadow-overlay tramp-rfn-eshadow-overlay)
-           (rfn-eshadow-update-overlay-hook nil))
-       (funcall (symbol-function 'rfn-eshadow-update-overlay)))
-      (widen))))
+      (save-excursion
+       (save-restriction
+         (narrow-to-region
+          (1+ (or (string-match "/" (buffer-string) end) end)) (point-max))
+         (let ((rfn-eshadow-overlay tramp-rfn-eshadow-overlay)
+               (rfn-eshadow-update-overlay-hook nil))
+           (funcall (symbol-function 'rfn-eshadow-update-overlay))))))))
 
 (when (boundp 'rfn-eshadow-update-overlay-hook)
   (add-hook 'rfn-eshadow-update-overlay-hook