diff options
Diffstat (limited to 'lisp')
-rw-r--r-- | lisp/eshell/em-hist.el | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lisp/eshell/em-hist.el b/lisp/eshell/em-hist.el index f4bfea798e0..573d06337db 100644 --- a/lisp/eshell/em-hist.el +++ b/lisp/eshell/em-hist.el @@ -840,7 +840,7 @@ If N is negative, find the next or Nth next match." (unless (minibuffer-window-active-p (selected-window)) (message "History item: %d" (- (ring-length eshell-history-ring) pos))) ;; Can't use kill-region as it sets this-command - (delete-region (save-excursion (eshell-bol) (point)) (point)) + (delete-region eshell-last-output-end (point)) (insert-and-inherit (eshell-get-history pos))))) (defun eshell-next-matching-input (regexp arg) |