Commit 9700caaf authored by Richard M. Stallman's avatar Richard M. Stallman
Browse files

(insert-directory): Fix prev change.

parent 12dd87fc
...@@ -2128,21 +2128,23 @@ If WILDCARD, it also runs the shell specified by `shell-file-name'." ...@@ -2128,21 +2128,23 @@ If WILDCARD, it also runs the shell specified by `shell-file-name'."
switches switches
(mapconcat 'identity switches " ") (mapconcat 'identity switches " ")
" " " "
pattern))) pattern))))
;; SunOS 4.1.3, SVr4 and others need the "." to list the ;; SunOS 4.1.3, SVr4 and others need the "." to list the
;; directory if FILE is a symbolic link. ;; directory if FILE is a symbolic link.
(apply 'call-process (apply 'call-process
insert-directory-program nil t nil insert-directory-program nil t nil
(let (list) (let (list)
(if (consp switches) (if (listp switches)
(setq list switches) (setq list switches)
;; Split the switches at any spaces (if (not (equal switches ""))
;; so we can pass separate options as separate args. (progn
(while (string-match " " switches) ;; Split the switches at any spaces
(setq list (cons (substring switches 0 (match-beginning 0)) ;; so we can pass separate options as separate args.
list) (while (string-match " " switches)
switches (substring switches (match-end 0)))) (setq list (cons (substring switches 0 (match-beginning 0))
(setq list (cons switches list))) list)
switches (substring switches (match-end 0))))
(setq list (cons switches list)))))
(append list (append list
(list (list
(if full-directory-p (if full-directory-p
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment