emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] Changes to emacs/lisp/vc.el,v


From: Martin Rudalics
Subject: [Emacs-diffs] Changes to emacs/lisp/vc.el,v
Date: Wed, 19 Dec 2007 09:25:19 +0000

CVSROOT:        /sources/emacs
Module name:    emacs
Changes by:     Martin Rudalics <m061211>       07/12/19 09:25:18

Index: vc.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/vc.el,v
retrieving revision 1.492
retrieving revision 1.493
diff -u -b -r1.492 -r1.493
--- vc.el       18 Dec 2007 08:25:34 -0000      1.492
+++ vc.el       19 Dec 2007 09:25:18 -0000      1.493
@@ -1297,7 +1297,10 @@
   "Make sure that the current buffer visits a version-controlled file."
   (if vc-dired-mode
       (set-buffer (find-file-noselect (dired-get-filename)))
-    (while vc-parent-buffer
+    (while (and vc-parent-buffer
+               ;; Avoid infinite looping when vc-parent-buffer and
+               ;; current buffer are the same buffer.
+               (not (eq vc-parent-buffer (current-buffer))))
       (set-buffer vc-parent-buffer))
     (if (not buffer-file-name)
        (error "Buffer %s is not associated with a file" (buffer-name))




reply via email to

[Prev in Thread] Current Thread [Next in Thread]