diff options
| author | Glenn Morris | 2015-06-13 16:41:55 -0700 |
|---|---|---|
| committer | Glenn Morris | 2015-06-13 16:41:55 -0700 |
| commit | e5ab4d92ec404531b5fa9d8fcbce5979a46b220a (patch) | |
| tree | e1661f556019b99efadd1d331a6421969e90e786 | |
| parent | 9bdd1c4c90bc19904f63361c32ebd4304f038aaf (diff) | |
| download | emacs-e5ab4d92ec404531b5fa9d8fcbce5979a46b220a.tar.gz emacs-e5ab4d92ec404531b5fa9d8fcbce5979a46b220a.zip | |
* lisp/startup.el (command-line-1): Inform if skipping relative
file names due to deleted PWD.
| -rw-r--r-- | lisp/startup.el | 15 |
1 files changed, 6 insertions, 9 deletions
diff --git a/lisp/startup.el b/lisp/startup.el index b389648f678..ab5a3a4bfa5 100644 --- a/lisp/startup.el +++ b/lisp/startup.el | |||
| @@ -2193,16 +2193,13 @@ A fancy display is used on graphic displays, normal otherwise." | |||
| 2193 | ;; to zero when `process-file-arg' returns. | 2193 | ;; to zero when `process-file-arg' returns. |
| 2194 | (process-file-arg | 2194 | (process-file-arg |
| 2195 | (lambda (name) | 2195 | (lambda (name) |
| 2196 | ;; If a relative filename was specified and | ||
| 2197 | ;; command-line-default-directory is nil, | ||
| 2198 | ;; silently drop that argument. | ||
| 2199 | ;; This can only happen if PWD is deleted. | 2196 | ;; This can only happen if PWD is deleted. |
| 2200 | ;; The warning about setting default-directory will | 2197 | (if (not (or dir (file-name-absolute-p name))) |
| 2201 | ;; clue you in. | 2198 | (message "Ignoring relative file name (%s) due to \ |
| 2202 | (when (and (or dir (file-name-absolute-p name)) | 2199 | nil default-directory" name) |
| 2203 | (let* ((file (expand-file-name | 2200 | (let* ((file (expand-file-name |
| 2204 | (command-line-normalize-file-name name) | 2201 | (command-line-normalize-file-name name) |
| 2205 | dir)) | 2202 | dir)) |
| 2206 | (buf (find-file-noselect file))) | 2203 | (buf (find-file-noselect file))) |
| 2207 | (setq displayable-buffers (cons buf displayable-buffers)) | 2204 | (setq displayable-buffers (cons buf displayable-buffers)) |
| 2208 | (with-current-buffer buf | 2205 | (with-current-buffer buf |
| @@ -2212,7 +2209,7 @@ A fancy display is used on graphic displays, normal otherwise." | |||
| 2212 | (setq line 0) | 2209 | (setq line 0) |
| 2213 | (unless (< column 1) | 2210 | (unless (< column 1) |
| 2214 | (move-to-column (1- column))) | 2211 | (move-to-column (1- column))) |
| 2215 | (setq column 0)))))))) | 2212 | (setq column 0))))))) |
| 2216 | 2213 | ||
| 2217 | ;; Add the long X options to longopts. | 2214 | ;; Add the long X options to longopts. |
| 2218 | (dolist (tem command-line-x-option-alist) | 2215 | (dolist (tem command-line-x-option-alist) |