diff options
| author | Eli Zaretskii | 2022-12-10 14:55:01 +0200 |
|---|---|---|
| committer | Eli Zaretskii | 2022-12-10 14:55:01 +0200 |
| commit | 1753da24cd44821bf39f03dc32476e320e732fca (patch) | |
| tree | de81bfbae53f45065ed3cc7e2be32bc340ec3c90 | |
| parent | 2f1269c3331bfe2b570a9238ce52dafb14c3cf7b (diff) | |
| download | emacs-1753da24cd44821bf39f03dc32476e320e732fca.tar.gz emacs-1753da24cd44821bf39f03dc32476e320e732fca.zip | |
Fix infloop in 'shell-resync-dirs' with tcsh
* lisp/shell.el (shell-resync-dirs): Remove trailing slash from
output of 'dirs', for csh/tcsh's sake. (Bug#59804)
| -rw-r--r-- | lisp/shell.el | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/lisp/shell.el b/lisp/shell.el index b396bc2b180..dadbdcbc034 100644 --- a/lisp/shell.el +++ b/lisp/shell.el | |||
| @@ -1162,6 +1162,7 @@ line output and parses it to form the new directory stack." | |||
| 1162 | (dlsl nil) | 1162 | (dlsl nil) |
| 1163 | (pos 0) | 1163 | (pos 0) |
| 1164 | (ds nil)) | 1164 | (ds nil)) |
| 1165 | (setq dls (string-trim-right dls "[ ]+")) | ||
| 1165 | ;; Split the dirlist into whitespace and non-whitespace chunks. | 1166 | ;; Split the dirlist into whitespace and non-whitespace chunks. |
| 1166 | ;; dlsl will be a reversed list of tokens. | 1167 | ;; dlsl will be a reversed list of tokens. |
| 1167 | (while (string-match "\\(\\S-+\\|\\s-+\\)" dls pos) | 1168 | (while (string-match "\\(\\S-+\\|\\s-+\\)" dls pos) |