emacs-devel
[Top][All Lists]
Advanced

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

~/{arch} causes an error in find-file


From: Masatake YAMATO
Subject: ~/{arch} causes an error in find-file
Date: Mon, 12 Apr 2004 12:39:43 +0900 (JST)

Hi,

After I created an tla archive at ~/{arch}, C-x C-f raise an error.
I have found that vc-workfile-version used in vc-arch-mode-line-string
returns nil. A temporary solution is attached.

Masatake YAMATO

2004-04-12  Masatake YAMATO  <address@hidden>

        * vc-arch.el (vc-arch-mode-line-string): Return an empty
        string if `vc-workfile-version' returns nil.

cvs diff: warning: unrecognized response `access control disabled, clients can 
connect from any host' from cvs server
Index: lisp/vc-arch.el
===================================================================
RCS file: /cvsroot/emacs/emacs/lisp/vc-arch.el,v
retrieving revision 1.5
diff -u -r1.5 vc-arch.el
--- lisp/vc-arch.el     23 Mar 2004 21:36:49 -0000      1.5
+++ lisp/vc-arch.el     12 Apr 2004 03:32:50 -0000
@@ -309,15 +309,18 @@
 (defun vc-arch-mode-line-string (file)
   "Return string for placement in modeline by `vc-mode-line' for FILE."
   (let ((rev (vc-workfile-version file)))
-    (dolist (rule vc-arch-mode-line-rewrite)
-      (if (string-match (car rule) rev)
-         (setq rev (replace-match (cdr rule) t nil rev))))
-    (format "Arch%c%s"
-           (case (vc-state file)
-             ((up-to-date needs-patch) ?-)
-             (added ?@)
-             (t ?:))
-           rev)))
+    (if rev
+       (progn
+         (dolist (rule vc-arch-mode-line-rewrite)
+           (if (string-match (car rule) rev)
+               (setq rev (replace-match (cdr rule) t nil rev))))
+         (format "Arch%c%s"
+                 (case (vc-state file)
+                   ((up-to-date needs-patch) ?-)
+                   (added ?@)
+                   (t ?:))
+                 rev))
+      "")))
 
 (defun vc-arch-diff3-rej-p (rej)
   (let ((attrs (file-attributes rej)))




reply via email to

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