diff options
Diffstat (limited to 'lisp/gnus/gnus-msg.el')
-rw-r--r-- | lisp/gnus/gnus-msg.el | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/lisp/gnus/gnus-msg.el b/lisp/gnus/gnus-msg.el index 6b093480940..7948efc2572 100644 --- a/lisp/gnus/gnus-msg.el +++ b/lisp/gnus/gnus-msg.el @@ -1871,11 +1871,13 @@ this is a reply." (when (and filep v) (setq v (with-temp-buffer (insert-file-contents v) - (goto-char (point-max)) - (skip-chars-backward "\n") - (delete-region (+ (point) (if (bolp) 0 1)) - (point-max)) - (buffer-string)))) + (buffer-substring + (point-min) + (progn + (goto-char (point-max)) + (if (zerop (skip-chars-backward "\n")) + (point) + (1+ (point)))))))) (setq results (delq (assoc element results) results)) (push (cons element v) results)))) ;; Now we have all the styles, so we insert them. |