vc-hg-state-slow: Run from the repository root

* lisp/vc/vc-hg.el (vc-hg-state-slow): Run command from the
repository root.  This fixes cases where a whole subdirectory no
longer exists.  We should return 'missing' for any files within
it.
This commit is contained in:
Sean Whitton 2026-06-23 11:28:19 +01:00
parent 3660bd3eb4
commit eb814fbb5c

View file

@ -236,7 +236,9 @@ A value of `default' means to use the value of `vc-resolve-conflicts'."
(setq file (expand-file-name file))
(let*
((status nil)
(default-directory (file-name-directory file))
(root (vc-hg-root file))
(file (file-relative-name file root))
(default-directory root)
(out
(with-output-to-string
(with-current-buffer