Mercurial > emacs
diff lisp/startup.el @ 112389:75fb060ecbc3
Don't mess with *temp*.
* lisp/obsolete/spell.el: Move from textmodes/spell.el.
(spell-string):
* lisp/term.el (term-read-input-ring):
* lisp/startup.el (display-startup-echo-area-message):
* lisp/progmodes/antlr-mode.el (antlr-directory-dependencies):
* lisp/gnus/message.el (message-mailer-swallows-blank-line):
* lisp/comint.el (comint-read-input-ring): Use with-temp-buffer.
* lisp/international/mule.el (ctext-pre-write-conversion):
Don't hardcode point-min==1.
* lisp/gnus/mm-util.el (mm-find-buffer-file-coding-system): Don't forget to
kill the temp buffer.
author | Stefan Monnier <monnier@iro.umontreal.ca> |
---|---|
date | Thu, 20 Jan 2011 17:36:12 -0500 |
parents | 61f7601898b1 |
children |
line wrap: on
line diff
--- a/lisp/startup.el Thu Jan 20 16:57:15 2011 -0500 +++ b/lisp/startup.el Thu Jan 20 17:36:12 2011 -0500 @@ -2017,7 +2017,7 @@ (defun display-startup-echo-area-message () (let ((resize-mini-windows t)) - (or noninteractive ;(input-pending-p) init-file-had-error + (or noninteractive ;(input-pending-p) init-file-had-error ;; t if the init file says to inhibit the echo area startup message. (and inhibit-startup-echo-area-message user-init-file @@ -2027,24 +2027,21 @@ (user-login-name) init-file-user))) ;; Wasn't set with custom; see if .emacs has a setq. - (let ((buffer (get-buffer-create " *temp*"))) - (prog1 - (condition-case nil - (with-current-buffer buffer - (insert-file-contents user-init-file) - (re-search-forward - (concat - "([ \t\n]*setq[ \t\n]+" - "inhibit-startup-echo-area-message[ \t\n]+" - (regexp-quote - (prin1-to-string - (if (equal init-file-user "") - (user-login-name) - init-file-user))) - "[ \t\n]*)") - nil t)) - (error nil)) - (kill-buffer buffer))))) + (condition-case nil + (with-temp-buffer + (insert-file-contents user-init-file) + (re-search-forward + (concat + "([ \t\n]*setq[ \t\n]+" + "inhibit-startup-echo-area-message[ \t\n]+" + (regexp-quote + (prin1-to-string + (if (equal init-file-user "") + (user-login-name) + init-file-user))) + "[ \t\n]*)") + nil t)) + (error nil)))) (message "%s" (startup-echo-area-message))))) (defun display-startup-screen (&optional concise)