summaryrefslogtreecommitdiff
path: root/lisp/vc/diff.el
diff options
context:
space:
mode:
Diffstat (limited to 'lisp/vc/diff.el')
-rw-r--r--lisp/vc/diff.el3
1 files changed, 3 insertions, 0 deletions
diff --git a/lisp/vc/diff.el b/lisp/vc/diff.el
index ac94586cace..ed5b49d3bf4 100644
--- a/lisp/vc/diff.el
+++ b/lisp/vc/diff.el
@@ -121,6 +121,8 @@ Possible values are:
nil -- no, it does not
check -- try to probe whether it does")
+(defvar diff-default-directory)
+
(defun diff-no-select (old new &optional switches no-async buf)
;; Noninteractive helper for creating and reverting diff buffers
(unless (bufferp new) (setq new (expand-file-name new)))
@@ -165,6 +167,7 @@ Possible values are:
(lambda (_ignore-auto _noconfirm)
(diff-no-select old new switches no-async (current-buffer))))
(setq default-directory thisdir)
+ (setq diff-default-directory default-directory)
(let ((inhibit-read-only t))
(insert command "\n"))
(if (and (not no-async) (fboundp 'make-process))