summaryrefslogtreecommitdiff
path: root/lisp/startup.el
diff options
context:
space:
mode:
authorRichard M. Stallman <rms@gnu.org>1995-10-08 19:30:41 +0000
committerRichard M. Stallman <rms@gnu.org>1995-10-08 19:30:41 +0000
commit421e225469d7e9d119b686c1a1d4ba1c94dbfee3 (patch)
tree55538b8992e5cce0e5269cb27cc15c76af732720 /lisp/startup.el
parent30333a034c04e666ff7225705e1cdf1a319afacf (diff)
downloademacs-421e225469d7e9d119b686c1a1d4ba1c94dbfee3.tar.gz
(command-line): Init user-mail-address here, after reading init file.
(normal-top-level): Not here.
Diffstat (limited to 'lisp/startup.el')
-rw-r--r--lisp/startup.el9
1 files changed, 6 insertions, 3 deletions
diff --git a/lisp/startup.el b/lisp/startup.el
index 772d619f889..987bb8b7814 100644
--- a/lisp/startup.el
+++ b/lisp/startup.el
@@ -275,9 +275,6 @@ this prefix to create a unique file name.")
(delete (concat "PWD=" pwd)
process-environment)))))))
(setq default-directory (abbreviate-file-name default-directory))
- (setq user-mail-address (concat (user-login-name) "@"
- (or mail-host-address
- (system-name))))
;; Specify the file for recording all the auto save files of this session.
;; This is used by recover-session.
(setq auto-save-list-file-name
@@ -525,6 +522,12 @@ this prefix to create a unique file name.")
(if debug-on-error-should-be-set
(setq debug-on-error debug-on-error-from-init-file)))
+ ;; Do this here in case the init file sets mail-host-address.
+ (or user-mail-address
+ (setq user-mail-address (concat (user-login-name) "@"
+ (or mail-host-address
+ (system-name)))))
+
(run-hooks 'after-init-hook)
;; If *scratch* exists and init file didn't change its mode, initialize it.