; Fix last change to vc-dir-recompute-file-state.

This commit is contained in:
Sean Whitton 2026-06-09 14:37:54 +01:00
parent 89bda8736a
commit abddd2075a

View file

@ -1275,14 +1275,14 @@ that file."
;; FIXME: Warning: UGLY HACK. The CVS backend caches the state ;; FIXME: Warning: UGLY HACK. The CVS backend caches the state
;; info, this forces the backend to update it. ;; info, this forces the backend to update it.
(vc-call-backend vc-dir-backend 'registered fname)) (vc-call-backend vc-dir-backend 'registered fname))
;; Ensure we return a nil state if the file does not exist so that (let ((state (vc-call-backend vc-dir-backend 'state fname))
;; it disappears from VC-Dir (bug#81191). (extra (vc-call-backend vc-dir-backend
(if (file-exists-p fname) 'status-fileinfo-extra fname)))
(list fname-short ;; Ensure we return a nil state if the file does not exist and is
(vc-call-backend vc-dir-backend 'state fname) ;; not tracked so that it disappears from VC-Dir (bug#81191).
(vc-call-backend vc-dir-backend (if (and (eq state 'up-to-date) (not (file-exists-p fname)))
'status-fileinfo-extra fname)) (list fname-short nil nil)
(list fname-short nil nil)))) (list fname-short state extra)))))
(defun vc-dir-find-child-files (dirname) (defun vc-dir-find-child-files (dirname)
;; Give a DIRNAME string return the list of all child files shown in ;; Give a DIRNAME string return the list of all child files shown in