From faeb73d448321a33160749dd66f6082843fc9862 Mon Sep 17 00:00:00 2001 From: Gerd Moellmann Date: Tue, 18 Apr 2000 13:04:46 +0000 Subject: [PATCH] (mail-do-fcc): Prevent inserting a newline at the start of an existing but empty folder. --- lisp/mail/sendmail.el | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lisp/mail/sendmail.el b/lisp/mail/sendmail.el index 9922fdae2f8..d5c0cb576ee 100644 --- a/lisp/mail/sendmail.el +++ b/lisp/mail/sendmail.el @@ -1079,6 +1079,10 @@ See also the function `select-message-coding-system'.") ;; unless we've already taken care of it. (unless dont-write-the-file (if (and (file-exists-p (car fcc-list)) + ;; Check that the file isn't empty. We don't + ;; want to insert a newline at the start of an + ;; empty file. + (not (zerop (nth 7 (file-attributes (car fcc-list))))) (mail-file-babyl-p (car fcc-list))) ;; If the file is a Babyl file, ;; convert the message to Babyl format. -- 2.39.5