diff options
| author | Andreas Schwab | 2007-08-29 13:35:16 +0000 |
|---|---|---|
| committer | Andreas Schwab | 2007-08-29 13:35:16 +0000 |
| commit | d9af69518ec6cb4688d5f860d6152458cf0a8fca (patch) | |
| tree | 90aa35aff62550f749e3618eb05e527d587b8b3c | |
| parent | 03f06e5cf509e901ee75ec96c697c383487bdae7 (diff) | |
| download | emacs-d9af69518ec6cb4688d5f860d6152458cf0a8fca.tar.gz emacs-d9af69518ec6cb4688d5f860d6152458cf0a8fca.zip | |
(shell): Return correct value from interactive spec.
| -rw-r--r-- | lisp/ChangeLog | 4 | ||||
| -rw-r--r-- | lisp/shell.el | 19 |
2 files changed, 14 insertions, 9 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 3f7758d2240..36418a1caa0 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,7 @@ | |||
| 1 | 2007-08-29 Andreas Schwab <schwab@suse.de> | ||
| 2 | |||
| 3 | * shell.el (shell): Return correct value from interactive spec. | ||
| 4 | |||
| 1 | 2007-08-29 Glenn Morris <rgm@gnu.org> | 5 | 2007-08-29 Glenn Morris <rgm@gnu.org> |
| 2 | 6 | ||
| 3 | * version.el (emacs-version): Increase to 23.0.50. | 7 | * version.el (emacs-version): Increase to 23.0.50. |
diff --git a/lisp/shell.el b/lisp/shell.el index 6c09654a0e5..392440ede81 100644 --- a/lisp/shell.el +++ b/lisp/shell.el | |||
| @@ -542,15 +542,16 @@ Otherwise, one argument `-i' is passed to the shell. | |||
| 542 | (interactive | 542 | (interactive |
| 543 | (list | 543 | (list |
| 544 | (and current-prefix-arg | 544 | (and current-prefix-arg |
| 545 | (read-buffer "Shell buffer: " | 545 | (prog1 |
| 546 | (generate-new-buffer-name "*shell*")) | 546 | (read-buffer "Shell buffer: " |
| 547 | (file-remote-p default-directory) | 547 | (generate-new-buffer-name "*shell*")) |
| 548 | ;; It must be possible to declare a local default-directory. | 548 | (if (file-remote-p default-directory) |
| 549 | (setq default-directory | 549 | ;; It must be possible to declare a local default-directory. |
| 550 | (expand-file-name | 550 | (setq default-directory |
| 551 | (read-file-name | 551 | (expand-file-name |
| 552 | "Default directory: " default-directory default-directory | 552 | (read-file-name |
| 553 | t nil 'file-directory-p)))))) | 553 | "Default directory: " default-directory default-directory |
| 554 | t nil 'file-directory-p)))))))) | ||
| 554 | (setq buffer (get-buffer-create (or buffer "*shell*"))) | 555 | (setq buffer (get-buffer-create (or buffer "*shell*"))) |
| 555 | ;; Pop to buffer, so that the buffer's window will be correctly set | 556 | ;; Pop to buffer, so that the buffer's window will be correctly set |
| 556 | ;; when we call comint (so that comint sets the COLUMNS env var properly). | 557 | ;; when we call comint (so that comint sets the COLUMNS env var properly). |