Commit efa3639b authored by Sam Steingold's avatar Sam Steingold
Browse files

(vc-hg-diff): Fix last patch: do not change directory.

parent e0620570
2009-11-18 Bernhard Herzog <>
* vc-hg.el (vc-hg-diff): Fix last patch: do not change directory.
2009-11-18 Juanma Barranquero <>
* font-setting.el (font-use-system-font): Declare for byte-compiler.
......@@ -276,16 +276,12 @@ If nil, use the value of `vc-diff-switches'. If t, use no switches."
(defun vc-hg-diff (files &optional oldvers newvers buffer)
"Get a difference report using hg between two revisions of FILES."
(let* ((firstfile (car files))
(cwd (if firstfile (file-name-directory firstfile)
(expand-file-name default-directory)))
(working (and firstfile (vc-working-revision firstfile))))
(when (and (equal oldvers working) (not newvers))
(setq oldvers nil))
(when (and (not oldvers) newvers)
(setq oldvers working))
(apply #'vc-hg-command (or buffer "*vc-diff*") nil
(mapcar (lambda (file) (file-relative-name file cwd)) files)
(apply #'vc-hg-command (or buffer "*vc-diff*") nil files "diff"
(vc-switches 'hg 'diff)
(when oldvers
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment