summaryrefslogtreecommitdiff
path: root/lisp
diff options
context:
space:
mode:
Diffstat (limited to 'lisp')
-rw-r--r--lisp/progmodes/grep.el5
1 files changed, 2 insertions, 3 deletions
diff --git a/lisp/progmodes/grep.el b/lisp/progmodes/grep.el
index c5e322a657a..aa81f8aa770 100644
--- a/lisp/progmodes/grep.el
+++ b/lisp/progmodes/grep.el
@@ -533,8 +533,7 @@ those sub directories of DIR."
(files
(read-string (concat "Search for \"" regexp "\" in files (default " grep-tree-last-files "): ")))
(dir
- (file-name-as-directory
- (read-directory-name "Base directory: " nil default-directory t))))
+ (read-directory-name "Base directory: " nil default-directory t)))
(list regexp files dir)))
(unless grep-tree-command
(grep-compute-defaults))
@@ -556,7 +555,7 @@ those sub directories of DIR."
nil) ;; we change default-directory to dir
(and grep-tree-ignore-CVS-directories "-path '*/CVS' -prune -o ")
grep-tree-ignore-case))
- (default-directory dir)
+ (default-directory (file-name-as-directory (expand-file-name dir)))
(null-device nil)) ; see grep
(grep command-args regexp)))