1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-04-27 08:43:40 -07:00

(display-warning): In batch mode,

exclude the final newline from the arg to `message'.
This commit is contained in:
Richard M. Stallman 2002-09-14 17:35:32 +00:00
parent facebc7bbb
commit bf2a6c399c
2 changed files with 12 additions and 1 deletions

View file

@ -1,3 +1,8 @@
2002-09-14 Richard M. Stallman <rms@gnu.org>
* warnings.el (display-warning): In batch mode,
exclude the final newline from the arg to `message'.
2002-09-13 Markus Rost <rost@math.ohio-state.edu>
* files.el (diff-buffer-with-file): Check whether associated file

View file

@ -257,7 +257,13 @@ See also `warning-series', `warning-prefix-function' and
;; Do this unconditionally, since there is no way
;; to view logged messages unless we output them.
(with-current-buffer buffer
(message "%s" (buffer-substring start end)))
(save-excursion
;; Don't include the final newline in the arg
;; to `message', because it adds a newline.
(goto-char end)
(if (bolp)
(forward-char -1))
(message "%s" (buffer-substring start (point)))))
;; Interactively, decide whether the warning merits
;; immediate display.
(or (< (warning-numeric-level level)