diff lisp/vc-arch.el @ 87574:21fcd219fd6e

* mouse.el (mouse-popup-menubar): Fix typo. * emacs-lisp/bytecomp.el (byte-compile-from-buffer): Move one more form inside with-current-buffer. * progmodes/antlr-mode.el (provide): Move to the end of file. (require): Don't require font-lock and compile. (outline-level, imenu-use-markers, imenu-create-index-function): Move declarations to top level. (cond-emacs-xemacs-macfn): Declare for compiler. * vc-bzr.el (vc-bzr-root): * vc-arch.el (vc-arch-root): Only set a property if the file is managed by this backend. * vc-hg.el (vc-hg-state): Support the new status code for up-to-date.
author Dan Nicolaescu <dann@ics.uci.edu>
date Fri, 04 Jan 2008 08:34:15 +0000
parents 613df1ba1584
children 107ccd98fa12
line wrap: on
line diff
--- a/lisp/vc-arch.el	Fri Jan 04 08:27:54 2008 +0000
+++ b/lisp/vc-arch.el	Fri Jan 04 08:34:15 2008 +0000
@@ -193,10 +193,12 @@
 (defun vc-arch-root (file)
   "Return the root directory of a Arch project, if any."
   (or (vc-file-getprop file 'arch-root)
-      (vc-file-setprop
-       ;; Check the =tagging-method, in case someone naively manually
-       ;; creates a {arch} directory somewhere.
-       file 'arch-root (vc-find-root file "{arch}/=tagging-method"))))
+      ;; Check the =tagging-method, in case someone naively manually
+      ;; creates a {arch} directory somewhere.
+      (let ((root (vc-find-root file "{arch}/=tagging-method")))
+	(when root
+	  (vc-file-setprop
+	   file 'arch-root root)))))
 
 (defun vc-arch-register (files &optional rev comment)
   (if rev (error "Explicit initial revision not supported for Arch"))