diff options
| author | Eli Zaretskii | 2005-11-26 10:51:22 +0000 |
|---|---|---|
| committer | Eli Zaretskii | 2005-11-26 10:51:22 +0000 |
| commit | 107dd21bcae503fa862f242006253b7f2738bfe3 (patch) | |
| tree | d83b45e5c54a74bbcf44abda5ff512ab764ff8de | |
| parent | bfc53c25fcf90592bc858d56f91f1e4cd53f6b02 (diff) | |
| download | emacs-107dd21bcae503fa862f242006253b7f2738bfe3.tar.gz emacs-107dd21bcae503fa862f242006253b7f2738bfe3.zip | |
(inferior-octave-startup): Force a non-empty string for secondary prompt PS2.
| -rw-r--r-- | lisp/progmodes/octave-inf.el | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/lisp/progmodes/octave-inf.el b/lisp/progmodes/octave-inf.el index 4f0875bbf99..67b5b108fa5 100644 --- a/lisp/progmodes/octave-inf.el +++ b/lisp/progmodes/octave-inf.el | |||
| @@ -220,6 +220,13 @@ startup file, `~/.emacs-octave'." | |||
| 220 | (concat (mapconcat | 220 | (concat (mapconcat |
| 221 | 'identity inferior-octave-output-list "\n") | 221 | 'identity inferior-octave-output-list "\n") |
| 222 | "\n")))) | 222 | "\n")))) |
| 223 | |||
| 224 | ;; An empty secondary prompt, as e.g. obtained by '--braindead', | ||
| 225 | ;; means trouble. | ||
| 226 | (inferior-octave-send-list-and-digest (list "PS2\n")) | ||
| 227 | (if (string-match "^PS2 = *$" (car inferior-octave-output-list)) | ||
| 228 | (inferior-octave-send-list-and-digest (list "PS2 = \"> \"\n"))) | ||
| 229 | |||
| 223 | ;; O.k., now we are ready for the Inferior Octave startup commands. | 230 | ;; O.k., now we are ready for the Inferior Octave startup commands. |
| 224 | (let* (commands | 231 | (let* (commands |
| 225 | (program (file-name-nondirectory inferior-octave-program)) | 232 | (program (file-name-nondirectory inferior-octave-program)) |