summaryrefslogtreecommitdiff
path: root/lisp
diff options
context:
space:
mode:
authorTino Calancha <tino.calancha@gmail.com>2017-07-03 12:55:06 +0900
committerTino Calancha <tino.calancha@gmail.com>2017-07-03 12:55:06 +0900
commitbc3dcd524dfb5c889ed017c093eaf028596fc35c (patch)
treef1c783db64e4b97127902888f71360071aa5e946 /lisp
parent1b4f0a92ff3505ef9a465b9b391756e3a73a6443 (diff)
downloademacs-bc3dcd524dfb5c889ed017c093eaf028596fc35c.tar.gz
emacs-bc3dcd524dfb5c889ed017c093eaf028596fc35c.tar.bz2
emacs-bc3dcd524dfb5c889ed017c093eaf028596fc35c.zip
dired-do-shell-command: Fix check for wildcards
* lisp/dired-aux.el (dired-do-shell-command): Replace just '?', '*' and '`?' i.e., keep the whitespaces. * test/lisp/dired-aux-tests.el (dired-test-bug27496): Add test.
Diffstat (limited to 'lisp')
-rw-r--r--lisp/dired-aux.el2
1 files changed, 1 insertions, 1 deletions
diff --git a/lisp/dired-aux.el b/lisp/dired-aux.el
index 12a97f8457e..e4547758587 100644
--- a/lisp/dired-aux.el
+++ b/lisp/dired-aux.el
@@ -738,7 +738,7 @@ can be produced by `dired-get-marked-files', for example."
;; Drop all ? and * surrounded by spaces and `?`.
(while (and (string-match regexp res)
(dired--star-or-qmark-p res str))
- (setq res (replace-match "" t t res 0)))
+ (setq res (replace-match "" t t res 2)))
(string-match regexp res))))
(let* ((on-each (not (dired--star-or-qmark-p command "*" 'keep)))
(no-subst (not (dired--star-or-qmark-p command "?" 'keep)))