Mercurial > emacs
comparison lisp/mail/sendmail.el @ 1741:bc25cbeb27c0
(mail-send): Don't clear modified or delete autosave if visiting a file.
author | Richard M. Stallman <rms@gnu.org> |
---|---|
date | Thu, 07 Jan 1993 10:18:46 +0000 |
parents | d4ea5385915f |
children | 0aa8e261f174 |
comparison
equal
deleted
inserted
replaced
1740:6d74de06a35d | 1741:bc25cbeb27c0 |
---|---|
239 (run-hooks 'mail-send-hook) | 239 (run-hooks 'mail-send-hook) |
240 (funcall send-mail-function) | 240 (funcall send-mail-function) |
241 ;; Now perform actions on successful sending. | 241 ;; Now perform actions on successful sending. |
242 (while mail-send-actions | 242 (while mail-send-actions |
243 (condition-case nil | 243 (condition-case nil |
244 (apply (car (car mail-send-actions)) (cdr (car mail-send-actions))) | 244 (apply (car (car mail-send-actions)) |
245 (cdr (car mail-send-actions))) | |
245 (error)) | 246 (error)) |
246 (setq mail-send-actions (cdr mail-send-actions))) | 247 (setq mail-send-actions (cdr mail-send-actions))) |
247 (set-buffer-modified-p nil) | 248 (message "Sending...done") |
248 (delete-auto-save-file-if-necessary t) | 249 ;; If buffer has no file, mark it as unmodified and delete autosave. |
249 (message "Sending...done")))) | 250 (if (not buffer-file-name) |
251 (progn | |
252 (set-buffer-modified-p nil) | |
253 (delete-auto-save-file-if-necessary t)))))) | |
250 | 254 |
251 (defun sendmail-send-it () | 255 (defun sendmail-send-it () |
252 (let ((errbuf (if mail-interactive | 256 (let ((errbuf (if mail-interactive |
253 (generate-new-buffer " sendmail errors") | 257 (generate-new-buffer " sendmail errors") |
254 0)) | 258 0)) |