summaryrefslogtreecommitdiff
path: root/lisp/gnus/mm-util.el
diff options
context:
space:
mode:
authorStefan Monnier <monnier@iro.umontreal.ca>2009-08-28 17:02:53 +0000
committerStefan Monnier <monnier@iro.umontreal.ca>2009-08-28 17:02:53 +0000
commit14acf2f55e96b3d01cd4f42508313a87d01c65cf (patch)
tree70cd72663c338877f2071ce88c562a17968afb20 /lisp/gnus/mm-util.el
parent72f16325c1807f5e822c2eb76e10392630842d39 (diff)
downloademacs-14acf2f55e96b3d01cd4f42508313a87d01c65cf.tar.gz
* gnus/nnheader.el (nnheader-find-file-noselect):
* gnus/mm-util.el (mm-insert-file-contents): * org/org-html.el (org-export-as-html): * org/org-docbook.el (org-export-as-docbook): * textmodes/reftex.el (reftex-get-file-buffer-force): * progmodes/verilog-mode.el (verilog-batch-execute-func): * emulation/viper.el (viper-go-away, viper-set-hooks): * emacs-lisp/re-builder.el (re-builder-unload-function): * emacs-lisp/bytecomp.el (byte-compile-file): * ses.el (ses-unload-function): * hexl.el (hexl-find-file): * files.el (normal-mode): * ehelp.el (with-electric-help): * autoinsert.el (auto-insert-alist): * arc-mode.el (archive-mode): Use (default-value 'major-mode) instead of default-major-mode.
Diffstat (limited to 'lisp/gnus/mm-util.el')
-rw-r--r--lisp/gnus/mm-util.el36
1 files changed, 18 insertions, 18 deletions
diff --git a/lisp/gnus/mm-util.el b/lisp/gnus/mm-util.el
index 403d967f8e4..8866befb4f9 100644
--- a/lisp/gnus/mm-util.el
+++ b/lisp/gnus/mm-util.el
@@ -1308,24 +1308,24 @@ to advanced Emacs features, such as file-name-handlers, format decoding,
`find-file-hooks', etc.
If INHIBIT is non-nil, inhibit `mm-inhibit-file-name-handlers'.
This function ensures that none of these modifications will take place."
- (let* ((format-alist nil)
- (auto-mode-alist (if inhibit nil (mm-auto-mode-alist)))
- (default-major-mode 'fundamental-mode)
- (enable-local-variables nil)
- (after-insert-file-functions nil)
- (enable-local-eval nil)
- (inhibit-file-name-operation (if inhibit
- 'insert-file-contents
- inhibit-file-name-operation))
- (inhibit-file-name-handlers
- (if inhibit
- (append mm-inhibit-file-name-handlers
- inhibit-file-name-handlers)
- inhibit-file-name-handlers))
- (ffh (if (boundp 'find-file-hook)
- 'find-file-hook
- 'find-file-hooks))
- (val (symbol-value ffh)))
+ (letf* ((format-alist nil)
+ (auto-mode-alist (if inhibit nil (mm-auto-mode-alist)))
+ ((default-value 'major-mode) 'fundamental-mode)
+ (enable-local-variables nil)
+ (after-insert-file-functions nil)
+ (enable-local-eval nil)
+ (inhibit-file-name-operation (if inhibit
+ 'insert-file-contents
+ inhibit-file-name-operation))
+ (inhibit-file-name-handlers
+ (if inhibit
+ (append mm-inhibit-file-name-handlers
+ inhibit-file-name-handlers)
+ inhibit-file-name-handlers))
+ (ffh (if (boundp 'find-file-hook)
+ 'find-file-hook
+ 'find-file-hooks))
+ (val (symbol-value ffh)))
(set ffh nil)
(unwind-protect
(insert-file-contents filename visit beg end replace)