changeset 1075:f402fe560fcd

entered into RCS
author Richard M. Stallman <rms@gnu.org>
date Fri, 04 Sep 1992 05:21:09 +0000
parents ab1964dc212c
children 8a936037cedc
files lisp/mail/sendmail.el
diffstat 1 files changed, 12 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/mail/sendmail.el	Thu Sep 03 00:23:47 1992 +0000
+++ b/lisp/mail/sendmail.el	Fri Sep 04 05:21:09 1992 +0000
@@ -323,6 +323,7 @@
 (defun mail-do-fcc (header-end)
   (let (fcc-list
 	(rmailbuf (current-buffer))
+	timezone
 	(tembuf (generate-new-buffer " rmail output"))
 	(case-fold-search t))
     (save-excursion
@@ -338,8 +339,19 @@
 		       (progn (forward-line 1) (point))))
       (set-buffer tembuf)
       (erase-buffer)
+      (call-process "date" nil t nil)
+      (goto-char (point-min))
+      (re-search-forward 
+        "[0-9] \\([A-Za-z][A-Za-z ]*[A-Za-z]\\)[0-9 ]*$")
+      (setq timezone (buffer-substring (match-beginning 1) (match-end 1)))
+      (erase-buffer)
       (insert "\nFrom " (user-login-name) " "
 	      (current-time-string) "\n")
+      ;; Insert the time zone before the year.
+      (forward-char -1)
+      (forward-word -1)
+      (insert timezone " ")
+      (goto-char (point-max))
       (insert-buffer-substring rmailbuf)
       ;; Make sure messages are separated.
       (goto-char (point-max))