diff options
| author | Richard M. Stallman | 1996-12-31 04:50:27 +0000 |
|---|---|---|
| committer | Richard M. Stallman | 1996-12-31 04:50:27 +0000 |
| commit | a8bf610ec0930235e2f98bba8bd70c233b1e9282 (patch) | |
| tree | 5b6893fa89319a0fc5efd4bab667ea92105148c8 | |
| parent | 63ba033ea116e1867e36c9b087b2efb62080ef3c (diff) | |
| download | emacs-a8bf610ec0930235e2f98bba8bd70c233b1e9282.tar.gz emacs-a8bf610ec0930235e2f98bba8bd70c233b1e9282.zip | |
(insert-directory): Use -- as arg
so that a file name or pattern is never taken as an option.
| -rw-r--r-- | lisp/files.el | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lisp/files.el b/lisp/files.el index 1341cd909b2..f62e7d9aa0c 100644 --- a/lisp/files.el +++ b/lisp/files.el | |||
| @@ -2726,7 +2726,7 @@ If WILDCARD, it also runs the shell specified by `shell-file-name'." | |||
| 2726 | (if (stringp switches) | 2726 | (if (stringp switches) |
| 2727 | switches | 2727 | switches |
| 2728 | (mapconcat 'identity switches " ")) | 2728 | (mapconcat 'identity switches " ")) |
| 2729 | " " | 2729 | " -- " |
| 2730 | pattern))) | 2730 | pattern))) |
| 2731 | ;; SunOS 4.1.3, SVr4 and others need the "." to list the | 2731 | ;; SunOS 4.1.3, SVr4 and others need the "." to list the |
| 2732 | ;; directory if FILE is a symbolic link. | 2732 | ;; directory if FILE is a symbolic link. |
| @@ -2745,6 +2745,8 @@ If WILDCARD, it also runs the shell specified by `shell-file-name'." | |||
| 2745 | switches (substring switches (match-end 0)))) | 2745 | switches (substring switches (match-end 0)))) |
| 2746 | (setq list (nreverse (cons switches list)))))) | 2746 | (setq list (nreverse (cons switches list)))))) |
| 2747 | (append list | 2747 | (append list |
| 2748 | ;; Avoid lossage if FILE starts with `-'. | ||
| 2749 | '("--") | ||
| 2748 | (list | 2750 | (list |
| 2749 | (if full-directory-p | 2751 | (if full-directory-p |
| 2750 | (concat (file-name-as-directory file) ".") | 2752 | (concat (file-name-as-directory file) ".") |