diff options
| -rw-r--r-- | lisp/comint.el | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/lisp/comint.el b/lisp/comint.el index 8ae8787d2e3..6e6691dea87 100644 --- a/lisp/comint.el +++ b/lisp/comint.el | |||
| @@ -1218,9 +1218,10 @@ Similarly for Soar, Scheme, etc." | |||
| 1218 | ;; functions used do insertion, rather than return | 1218 | ;; functions used do insertion, rather than return |
| 1219 | ;; strings. We have to expand, then insert back. | 1219 | ;; strings. We have to expand, then insert back. |
| 1220 | (comint-replace-by-expanded-history t) | 1220 | (comint-replace-by-expanded-history t) |
| 1221 | (let ((copy (buffer-substring pmark (point)))) | 1221 | (let ((copy (buffer-substring pmark (point))) |
| 1222 | (delete-region pmark (point)) | 1222 | (start (point))) |
| 1223 | (insert-before-markers input) | 1223 | (insert input) |
| 1224 | (delete-region pmark start) | ||
| 1224 | copy)))) | 1225 | copy)))) |
| 1225 | (if comint-process-echoes | 1226 | (if comint-process-echoes |
| 1226 | (delete-region pmark (point)) | 1227 | (delete-region pmark (point)) |