From: Andreas Schwab Date: Tue, 4 Jan 2005 15:25:43 +0000 (+0000) Subject: (insert-directory): Only look for error lines in X-Git-Tag: ttn-vms-21-2-B4~2927 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=11bd2f9c9b6e1d2af39f2aab177614086e5a0aa4;p=emacs.git (insert-directory): Only look for error lines in inserted text. Don't move too far after processing --dired markers. --- diff --git a/lisp/files.el b/lisp/files.el index a4a102c9586..cdaa7a5adb8 100644 --- a/lisp/files.el +++ b/lisp/files.el @@ -4560,7 +4560,7 @@ normally equivalent short `-D' option is just passed on to error-lines) ;; Find all the lines that are error messages, ;; and record the bounds of each one. - (goto-char (point-min)) + (goto-char beg) (while (< (point) linebeg) (or (eql (following-char) ?\s) (push (list (point) (line-end-position)) error-lines)) @@ -4586,11 +4586,9 @@ normally equivalent short `-D' option is just passed on to (end-of-line)))) (goto-char end) (beginning-of-line) - (delete-region (point) (progn (forward-line 2) (point)))) - (forward-line 1) + (delete-region (point) (progn (forward-line 1) (point)))) (if (looking-at "//DIRED-OPTIONS//") - (delete-region (point) (progn (forward-line 1) (point))) - (forward-line 1)))) + (delete-region (point) (progn (forward-line 1) (point)))))) ;; Now decode what read if necessary. (let ((coding (or coding-system-for-read