diff options
author | Glenn Morris <[email protected]> | 2012-01-10 21:24:02 -0500 |
---|---|---|
committer | Glenn Morris <[email protected]> | 2012-01-10 21:24:02 -0500 |
commit | e52c37fad057b29d68c51cf3a70b2e0d94f656cb (patch) | |
tree | f90ec4a353978c7c0636c6499ec91e8f1a97aa01 | |
parent | ce316182baa016f42348a69da69cab3f319ad2fa (diff) |
* lisp/dired-aux.el (dired-do-shell-command): Fix */? logic. (Bug#6561)
-rw-r--r-- | lisp/ChangeLog | 4 | ||||
-rw-r--r-- | lisp/dired-aux.el | 12 |
2 files changed, 10 insertions, 6 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 2f28fe36d3..7cdb5217c1 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2012-01-11 Glenn Morris <[email protected]> + + * dired-aux.el (dired-do-shell-command): Fix */? logic. (Bug#6561) + 2012-01-10 Chong Yidong <[email protected]> * net/network-stream.el (network-stream-open-starttls): Avoid diff --git a/lisp/dired-aux.el b/lisp/dired-aux.el index 31d8afc4fc..19ed74b207 100644 --- a/lisp/dired-aux.el +++ b/lisp/dired-aux.el @@ -605,16 +605,16 @@ can be produced by `dired-get-marked-files', for example." current-prefix-arg files))) (let* ((on-each (not (string-match dired-star-subst-regexp command))) - (subst (not (string-match dired-quark-subst-regexp command))) - (star (not (string-match "\\*" command))) - (qmark (not (string-match "\\?" command)))) + (no-subst (not (string-match dired-quark-subst-regexp command))) + (star (string-match "\\*" command)) + (qmark (string-match "\\?" command))) ;; Get confirmation for wildcards that may have been meant ;; to control substitution of a file name or the file name list. - (if (cond ((not (or on-each subst)) + (if (cond ((not (or on-each no-subst)) (error "You can not combine `*' and `?' substitution marks")) - ((and star (not on-each)) + ((and star on-each) (y-or-n-p "Confirm--do you mean to use `*' as a wildcard? ")) - ((and qmark (not subst)) + ((and qmark no-subst) (y-or-n-p "Confirm--do you mean to use `?' as a wildcard? ")) (t)) (if on-each |