summaryrefslogtreecommitdiff
path: root/lisp/ls-lisp.el
diff options
context:
space:
mode:
Diffstat (limited to 'lisp/ls-lisp.el')
-rw-r--r--lisp/ls-lisp.el3
1 files changed, 3 insertions, 0 deletions
diff --git a/lisp/ls-lisp.el b/lisp/ls-lisp.el
index 54c76a9d725..b6621b08566 100644
--- a/lisp/ls-lisp.el
+++ b/lisp/ls-lisp.el
@@ -216,6 +216,9 @@ that work are: A a c i r S s t u U X g G B C R and F partly."
(if handler
(funcall handler 'insert-directory file switches
wildcard full-directory-p)
+ ;; Remove --dired switch
+ (if (string-match "--dired " switches)
+ (setq switches (replace-match "" nil nil switches)))
;; Convert SWITCHES to a list of characters.
(setq switches (delete ?- (append switches nil)))
(if wildcard