summaryrefslogtreecommitdiff
path: root/contrib/emacs
diff options
context:
space:
mode:
authorAlexandre Julliard <julliard@winehq.org>2006-12-22 13:56:15 (GMT)
committerJunio C Hamano <junkio@cox.net>2006-12-23 07:14:43 (GMT)
commit4de0f9f9b6ed1731de00b67952504e5a783f54a4 (patch)
tree869be292be3ce053593ec5c3ef2dfab410716219 /contrib/emacs
parent40f656cd0214355df4c29aea315bfc2e9d983516 (diff)
downloadgit-4de0f9f9b6ed1731de00b67952504e5a783f54a4.zip
git-4de0f9f9b6ed1731de00b67952504e5a783f54a4.tar.gz
git-4de0f9f9b6ed1731de00b67952504e5a783f54a4.tar.bz2
vc-git: Ignore errors caused by a non-existent directory in vc-git-registered.
Signed-off-by: Alexandre Julliard <julliard@winehq.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'contrib/emacs')
-rw-r--r--contrib/emacs/vc-git.el5
1 files changed, 3 insertions, 2 deletions
diff --git a/contrib/emacs/vc-git.el b/contrib/emacs/vc-git.el
index 8b636192..3eb4bd1 100644
--- a/contrib/emacs/vc-git.el
+++ b/contrib/emacs/vc-git.el
@@ -58,8 +58,9 @@
(with-temp-buffer
(let* ((dir (file-name-directory file))
(name (file-relative-name file dir)))
- (when dir (cd dir))
- (and (ignore-errors (eq 0 (call-process "git" nil '(t nil) nil "ls-files" "-c" "-z" "--" name)))
+ (and (ignore-errors
+ (when dir (cd dir))
+ (eq 0 (call-process "git" nil '(t nil) nil "ls-files" "-c" "-z" "--" name)))
(let ((str (buffer-string)))
(and (> (length str) (length name))
(string= (substring str 0 (1+ (length name))) (concat name "\0"))))))))