aboutsummaryrefslogtreecommitdiffstats
path: root/lisp
diff options
context:
space:
mode:
authorEli Zaretskii2013-02-09 14:52:01 +0200
committerEli Zaretskii2013-02-09 14:52:01 +0200
commit8549f9e89bd9288c4c709d183a5bf8f07dbeed3d (patch)
treed1c618cc8dd547322911fc5dab74b7a3235f6448 /lisp
parent2cdd55fc764336b5dee1e69842b9cc2d28976041 (diff)
downloademacs-8549f9e89bd9288c4c709d183a5bf8f07dbeed3d.tar.gz
emacs-8549f9e89bd9288c4c709d183a5bf8f07dbeed3d.zip
Remove all references to buffer-file-type and related features.
src/xdisp.c (decode_mode_spec): Remove handling of %t. lisp/net/ange-ftp.el (ange-ftp-insert-file-contents): Don't reference buffer-file-type. lisp/mail/feedmail.el (feedmail-force-binary-write): Doc fix. (feedmail-run-the-queue, feedmail-dump-message-to-queue) (feedmail-send-it-immediately): Don't bind buffer-file-type, bind coding-system-for-write instead. lisp/jka-compr.el (jka-compr-write-region): Don't bind buffer-file-type. lisp/emacs-lisp/bytecomp.el (byte-compile-file): Don't bind buffer-file-type. lisp/files.el (file-name-buffer-file-type-alist): Remove defvar. (insert-file-contents-literally): Remove reference to file-name-buffer-file-type-alist. lisp/dos-w32.el (file-name-buffer-file-type-alist): Deprecate and make-obsolete. (find-buffer-file-type-match, find-buffer-file-type): Remove. (find-buffer-file-type-coding-system): Remove references to find-buffer-file-type-match, find-buffer-file-type, and buffer-file-type. Don't put find-buffer-file-type-coding-system into file-coding-system-alist. (find-file-binary, find-file-text): Bind coding-system-for-read instead of file-name-buffer-file-type-alist. lisp/erc/erc-dcc.el (erc-dcc-get-file): Don't reference buffer-file-type. doc/emacs/msdog.texi (Text and Binary): Delete the description of file-name-buffer-file-type-alist. doc/lispref/modes.texi (%-Constructs): Remove the description of %t. doc/lispref/nonascii.texi (MS-DOS File Types): Delete node. Fixes: debbugs:12989
Diffstat (limited to 'lisp')
-rw-r--r--lisp/ChangeLog31
-rw-r--r--lisp/arc-mode.el5
-rw-r--r--lisp/dos-w32.el90
-rw-r--r--lisp/emacs-lisp/bytecomp.el2
-rw-r--r--lisp/erc/ChangeLog4
-rw-r--r--lisp/erc/erc-dcc.el1
-rw-r--r--lisp/files.el3
-rw-r--r--lisp/jka-compr.el2
-rw-r--r--lisp/mail/feedmail.el23
-rw-r--r--lisp/net/ange-ftp.el6
10 files changed, 76 insertions, 91 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index f5b6daf16d8..0712f9a1fc8 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,34 @@
12013-02-09 Eli Zaretskii <eliz@gnu.org>
2
3 * net/ange-ftp.el (ange-ftp-insert-file-contents): Don't reference
4 buffer-file-type.
5
6 * mail/feedmail.el (feedmail-force-binary-write): Doc fix.
7 (feedmail-run-the-queue, feedmail-dump-message-to-queue)
8 (feedmail-send-it-immediately): Don't bind buffer-file-type, bind
9 coding-system-for-write instead.
10
11 * jka-compr.el (jka-compr-write-region): Don't bind
12 buffer-file-type.
13
14 * emacs-lisp/bytecomp.el (byte-compile-file): Don't bind
15 buffer-file-type.
16
17 * files.el (file-name-buffer-file-type-alist): Remove defvar.
18 (insert-file-contents-literally): Remove reference to
19 file-name-buffer-file-type-alist.
20
21 * dos-w32.el (file-name-buffer-file-type-alist): Deprecate and
22 make-obsolete.
23 (find-buffer-file-type-match, find-buffer-file-type): Remove.
24 (find-buffer-file-type-coding-system): Remove references to
25 find-buffer-file-type-match, find-buffer-file-type, and
26 buffer-file-type.
27 Don't put find-buffer-file-type-coding-system into
28 file-coding-system-alist.
29 (find-file-binary, find-file-text): Bind coding-system-for-read
30 instead of file-name-buffer-file-type-alist.
31
12013-02-09 Tassilo Horn <tsdh@gnu.org> 322013-02-09 Tassilo Horn <tsdh@gnu.org>
2 33
3 * doc-view.el: Use (and prefer) soffice as default ODF->PDF 34 * doc-view.el: Use (and prefer) soffice as default ODF->PDF
diff --git a/lisp/arc-mode.el b/lisp/arc-mode.el
index 8849fb85244..4fc04b706b5 100644
--- a/lisp/arc-mode.el
+++ b/lisp/arc-mode.el
@@ -975,11 +975,6 @@ using `make-temp-file', and the generated name is returned."
975 (save-excursion 975 (save-excursion
976 (funcall set-auto-coding-function 976 (funcall set-auto-coding-function
977 filename (- (point-max) (point-min))))) 977 filename (- (point-max) (point-min)))))
978 ;; dos-w32.el defines the function
979 ;; find-buffer-file-type-coding-system for DOS/Windows
980 ;; systems which preserves the coding-system of existing files.
981 ;; (That function is called via file-coding-system-alist.)
982 ;; Here, we want it to act as if the extracted file existed.
983 ;; The following let-binding of file-name-handler-alist forces 978 ;; The following let-binding of file-name-handler-alist forces
984 ;; find-file-not-found-set-buffer-file-coding-system to ignore 979 ;; find-file-not-found-set-buffer-file-coding-system to ignore
985 ;; the file's name (see dos-w32.el). 980 ;; the file's name (see dos-w32.el).
diff --git a/lisp/dos-w32.el b/lisp/dos-w32.el
index 5866edfc3d6..d6788ffe028 100644
--- a/lisp/dos-w32.el
+++ b/lisp/dos-w32.el
@@ -37,7 +37,7 @@
37;; Set the null device (for compile.el). 37;; Set the null device (for compile.el).
38(setq null-device "NUL") 38(setq null-device "NUL")
39 39
40;; For distinguishing file types based upon suffixes. 40;; For distinguishing file types based upon suffixes. DEPRECATED, DO NOT USE!
41(defcustom file-name-buffer-file-type-alist 41(defcustom file-name-buffer-file-type-alist
42 '(("[:/].*config.sys$" . nil) ; config.sys text 42 '(("[:/].*config.sys$" . nil) ; config.sys text
43 ("\\.\\(obj\\|exe\\|com\\|lib\\|sys\\|bin\\|ico\\|pif\\|class\\)$" . t) 43 ("\\.\\(obj\\|exe\\|com\\|lib\\|sys\\|bin\\|ico\\|pif\\|class\\)$" . t)
@@ -54,36 +54,18 @@
54 ("\\.tp[ulpw]$" . t) ; borland Pascal stuff 54 ("\\.tp[ulpw]$" . t) ; borland Pascal stuff
55 ("[:/]tags$" . nil) ; emacs TAGS file 55 ("[:/]tags$" . nil) ; emacs TAGS file
56 ) 56 )
57 "Alist for distinguishing text files from binary files. 57 "Alist used in the past for distinguishing text files from binary files.
58Each element has the form (REGEXP . TYPE), where REGEXP is matched 58Each element has the form (REGEXP . TYPE), where REGEXP is matched
59against the file name, and TYPE is nil for text, t for binary." 59against the file name, and TYPE is nil for text, t for binary.
60
61This variable is deprecated, not used anywhere, and will soon be deleted."
60 :type '(repeat (cons regexp boolean)) 62 :type '(repeat (cons regexp boolean))
61 :group 'dos-fns 63 :group 'dos-fns
62 :group 'w32) 64 :group 'w32)
63 65
64;; Return the pair matching filename on file-name-buffer-file-type-alist, 66(make-obsolete-variable 'file-name-buffer-file-type-alist
65;; or nil otherwise. 67 'file-coding-system-alist
66(defun find-buffer-file-type-match (filename) 68 "24.4")
67 (let ((alist file-name-buffer-file-type-alist)
68 (found nil))
69 (let ((case-fold-search t))
70 (setq filename (file-name-sans-versions filename))
71 (while (and (not found) alist)
72 (if (string-match (car (car alist)) filename)
73 (setq found (car alist)))
74 (setq alist (cdr alist)))
75 found)))
76
77;; Don't check for untranslated file systems here.
78(defun find-buffer-file-type (filename)
79 (let ((match (find-buffer-file-type-match filename))
80 (code))
81 (if (not match)
82 (default-value 'buffer-file-type)
83 (setq code (cdr match))
84 (cond ((memq code '(nil t)) code)
85 ((and (symbolp code) (fboundp code))
86 (funcall code filename))))))
87 69
88(setq-default buffer-file-coding-system 'undecided-dos) 70(setq-default buffer-file-coding-system 'undecided-dos)
89 71
@@ -99,9 +81,6 @@ and whether the file exists:
99 If it matches in `untranslated-filesystem-list': 81 If it matches in `untranslated-filesystem-list':
100 If the file exists: `undecided' 82 If the file exists: `undecided'
101 If the file does not exist: `undecided-unix' 83 If the file does not exist: `undecided-unix'
102 If it matches in `file-name-buffer-file-type-alist':
103 If the match is t (for binary): `no-conversion'
104 If the match is nil (for dos-text): `undecided-dos'
105 Otherwise: 84 Otherwise:
106 If the file exists: `undecided' 85 If the file exists: `undecided'
107 If the file does not exist default value of `buffer-file-coding-system' 86 If the file does not exist default value of `buffer-file-coding-system'
@@ -110,25 +89,23 @@ Note that the CAR of arguments to `insert-file-contents' operation could
110be a cons cell of the form \(FILENAME . BUFFER\), where BUFFER is a buffer 89be a cons cell of the form \(FILENAME . BUFFER\), where BUFFER is a buffer
111into which the file's contents were already read, but not yet decoded. 90into which the file's contents were already read, but not yet decoded.
112 91
113If operation is `write-region', the coding system is chosen based upon 92If operation is `write-region', the coding system is chosen based
114the value of `buffer-file-coding-system' and `buffer-file-type'. If 93upon the value of `buffer-file-coding-system'. If
115`buffer-file-coding-system' is non-nil, its value is used. If it is 94`buffer-file-coding-system' is non-nil, its value is used.
116nil and `buffer-file-type' is t, the coding system is `no-conversion'.
117Otherwise, it is `undecided-dos'. 95Otherwise, it is `undecided-dos'.
118 96
119The two most common situations are when DOS and Unix files are read 97The most common situation is when DOS and Unix files are read and
120and written, and their names do not match in 98written, and their names do not match in `untranslated-filesystem-list'.
121`untranslated-filesystem-list' and `file-name-buffer-file-type-alist'. 99In these cases, the coding system initially will be `undecided'.
122In these cases, the coding system initially will be `undecided'. As 100As the file is read in the DOS case, the coding system will be
123the file is read in the DOS case, the coding system will be changed to 101changed to `undecided-dos' as CR/LFs are detected. As the file
124`undecided-dos' as CR/LFs are detected. As the file is read in the 102is read in the Unix case, the coding system will be changed to
125Unix case, the coding system will be changed to `undecided-unix' as 103`undecided-unix' as LFs are detected. In both cases,
126LFs are detected. In both cases, `buffer-file-coding-system' will be 104`buffer-file-coding-system' will be set to the appropriate coding
127set to the appropriate coding system, and the value of 105system, and the value of `buffer-file-coding-system' will be used
128`buffer-file-coding-system' will be used when writing the file." 106when writing the file."
129 107
130 (let ((op (nth 0 command)) 108 (let ((op (nth 0 command))
131 (binary nil) (text nil)
132 (undecided nil) (undecided-unix nil) 109 (undecided nil) (undecided-unix nil)
133 target target-buf) 110 target target-buf)
134 (cond ((eq op 'insert-file-contents) 111 (cond ((eq op 'insert-file-contents)
@@ -144,15 +121,8 @@ set to the appropriate coding system, and the value of
144 (and (bufferp (cdr target)) 121 (and (bufferp (cdr target))
145 (buffer-name (cdr target)))) 122 (buffer-name (cdr target))))
146 (setq target (car target))) 123 (setq target (car target)))
147 ;; First check for a file name that indicates 124 (cond ((or
148 ;; it is truly binary. 125 ;; For any existing file, decide based on contents.
149 (setq binary (find-buffer-file-type target))
150 (cond (binary)
151 ;; Next check for files that MUST use DOS eol conversion.
152 ((find-buffer-file-type-match target)
153 (setq text t))
154 ;; For any other existing file, decide based on contents.
155 ((or
156 (file-exists-p target) 126 (file-exists-p target)
157 ;; If TARGET does not exist as a file, replace its 127 ;; If TARGET does not exist as a file, replace its
158 ;; base name with TARGET-BUF and try again. This 128 ;; base name with TARGET-BUF and try again. This
@@ -167,9 +137,7 @@ set to the appropriate coding system, and the value of
167 ;; Next check for a non-DOS file system. 137 ;; Next check for a non-DOS file system.
168 ((untranslated-file-p target) 138 ((untranslated-file-p target)
169 (setq undecided-unix t))) 139 (setq undecided-unix t)))
170 (cond (binary '(no-conversion . no-conversion)) 140 (cond (undecided-unix '(undecided-unix . undecided-unix))
171 (text '(undecided-dos . undecided-dos))
172 (undecided-unix '(undecided-unix . undecided-unix))
173 (undecided '(undecided . undecided)) 141 (undecided '(undecided . undecided))
174 (t (cons (default-value 'buffer-file-coding-system) 142 (t (cons (default-value 'buffer-file-coding-system)
175 (default-value 'buffer-file-coding-system))))) 143 (default-value 'buffer-file-coding-system)))))
@@ -180,22 +148,18 @@ set to the appropriate coding system, and the value of
180 ;; Normally this is used only in a non-file-visiting 148 ;; Normally this is used only in a non-file-visiting
181 ;; buffer, because normally buffer-file-coding-system is non-nil 149 ;; buffer, because normally buffer-file-coding-system is non-nil
182 ;; in a file-visiting buffer. 150 ;; in a file-visiting buffer.
183 (if buffer-file-type 151 '(undecided-dos . undecided-dos))))))
184 '(no-conversion . no-conversion)
185 '(undecided-dos . undecided-dos)))))))
186
187(modify-coding-system-alist 'file "" 'find-buffer-file-type-coding-system)
188 152
189(defun find-file-binary (filename) 153(defun find-file-binary (filename)
190 "Visit file FILENAME and treat it as binary." 154 "Visit file FILENAME and treat it as binary."
191 (interactive "FFind file binary: ") 155 (interactive "FFind file binary: ")
192 (let ((file-name-buffer-file-type-alist '(("" . t)))) 156 (let ((coding-system-for-read 'no-conversion))
193 (find-file filename))) 157 (find-file filename)))
194 158
195(defun find-file-text (filename) 159(defun find-file-text (filename)
196 "Visit file FILENAME and treat it as a text file." 160 "Visit file FILENAME and treat it as a text file."
197 (interactive "FFind file text: ") 161 (interactive "FFind file text: ")
198 (let ((file-name-buffer-file-type-alist '(("" . nil)))) 162 (let ((coding-system-for-read 'undecided-dos))
199 (find-file filename))) 163 (find-file filename)))
200 164
201(defun find-file-not-found-set-buffer-file-coding-system () 165(defun find-file-not-found-set-buffer-file-coding-system ()
diff --git a/lisp/emacs-lisp/bytecomp.el b/lisp/emacs-lisp/bytecomp.el
index 4e002cfc8cb..280a1bbc2dd 100644
--- a/lisp/emacs-lisp/bytecomp.el
+++ b/lisp/emacs-lisp/bytecomp.el
@@ -1795,8 +1795,6 @@ The value is non-nil if there were no errors, nil if errors."
1795 (kill-emacs-hook 1795 (kill-emacs-hook
1796 (cons (lambda () (ignore-errors (delete-file tempfile))) 1796 (cons (lambda () (ignore-errors (delete-file tempfile)))
1797 kill-emacs-hook))) 1797 kill-emacs-hook)))
1798 (if (memq system-type '(ms-dos 'windows-nt))
1799 (setq buffer-file-type t))
1800 (write-region (point-min) (point-max) tempfile nil 1) 1798 (write-region (point-min) (point-max) tempfile nil 1)
1801 ;; This has the intentional side effect that any 1799 ;; This has the intentional side effect that any
1802 ;; hard-links to target-file continue to 1800 ;; hard-links to target-file continue to
diff --git a/lisp/erc/ChangeLog b/lisp/erc/ChangeLog
index bbe551c735d..cc7624dee03 100644
--- a/lisp/erc/ChangeLog
+++ b/lisp/erc/ChangeLog
@@ -1,3 +1,7 @@
12013-02-09 Eli Zaretskii <eliz@gnu.org>
2
3 * erc-dcc.el (erc-dcc-get-file): Don't reference buffer-file-type.
4
12013-01-11 Dmitry Antipov <dmantipov@yandex.ru> 52013-01-11 Dmitry Antipov <dmantipov@yandex.ru>
2 6
3 * erc-dcc.el (erc-dcc-send-file): Use point-min-marker. 7 * erc-dcc.el (erc-dcc-send-file): Use point-min-marker.
diff --git a/lisp/erc/erc-dcc.el b/lisp/erc/erc-dcc.el
index c27bb629f9d..acb8febea80 100644
--- a/lisp/erc/erc-dcc.el
+++ b/lisp/erc/erc-dcc.el
@@ -942,7 +942,6 @@ filter and a process sentinel, and making the connection."
942 (set-buffer-multibyte nil)) 942 (set-buffer-multibyte nil))
943 943
944 (setq mode-line-process '(":%s") 944 (setq mode-line-process '(":%s")
945 buffer-file-type t
946 buffer-read-only t) 945 buffer-read-only t)
947 (setq erc-dcc-file-name file) 946 (setq erc-dcc-file-name file)
948 947
diff --git a/lisp/files.el b/lisp/files.el
index 3bc3059c68f..9fca70d36f7 100644
--- a/lisp/files.el
+++ b/lisp/files.el
@@ -1983,8 +1983,6 @@ Do you want to revisit the file normally now? ")
1983 (after-find-file error (not nowarn))) 1983 (after-find-file error (not nowarn)))
1984 (current-buffer)))) 1984 (current-buffer))))
1985 1985
1986(defvar file-name-buffer-file-type-alist) ;From dos-w32.el.
1987
1988(defun insert-file-contents-literally (filename &optional visit beg end replace) 1986(defun insert-file-contents-literally (filename &optional visit beg end replace)
1989 "Like `insert-file-contents', but only reads in the file literally. 1987 "Like `insert-file-contents', but only reads in the file literally.
1990A buffer may be modified in several ways after reading into the buffer, 1988A buffer may be modified in several ways after reading into the buffer,
@@ -1996,7 +1994,6 @@ This function ensures that none of these modifications will take place."
1996 (after-insert-file-functions nil) 1994 (after-insert-file-functions nil)
1997 (coding-system-for-read 'no-conversion) 1995 (coding-system-for-read 'no-conversion)
1998 (coding-system-for-write 'no-conversion) 1996 (coding-system-for-write 'no-conversion)
1999 (file-name-buffer-file-type-alist '(("" . t)))
2000 (inhibit-file-name-handlers 1997 (inhibit-file-name-handlers
2001 ;; FIXME: Yuck!! We should turn insert-file-contents-literally 1998 ;; FIXME: Yuck!! We should turn insert-file-contents-literally
2002 ;; into a file operation instead! 1999 ;; into a file operation instead!
diff --git a/lisp/jka-compr.el b/lisp/jka-compr.el
index ac81cf0d52d..5664a890cb1 100644
--- a/lisp/jka-compr.el
+++ b/lisp/jka-compr.el
@@ -332,8 +332,6 @@ There should be no more than seven characters after the final `/'."
332 332
333 (with-current-buffer temp-buffer 333 (with-current-buffer temp-buffer
334 (let ((coding-system-for-write 'no-conversion)) 334 (let ((coding-system-for-write 'no-conversion))
335 (if (memq system-type '(ms-dos windows-nt))
336 (setq buffer-file-type t) )
337 (jka-compr-run-real-handler 'write-region 335 (jka-compr-run-real-handler 'write-region
338 (list (point-min) (point-max) 336 (list (point-min) (point-max)
339 filename 337 filename
diff --git a/lisp/mail/feedmail.el b/lisp/mail/feedmail.el
index 4305094611a..0502e7f9487 100644
--- a/lisp/mail/feedmail.el
+++ b/lisp/mail/feedmail.el
@@ -590,7 +590,7 @@ header is fiddled after the From: header is fiddled."
590(defcustom feedmail-force-binary-write t 590(defcustom feedmail-force-binary-write t
591 "If non-nil, force writing file as binary (this applies to queues and Fcc:). 591 "If non-nil, force writing file as binary (this applies to queues and Fcc:).
592On systems where there is a difference between binary and text files, 592On systems where there is a difference between binary and text files,
593feedmail will temporarily manipulate the value of `buffer-file-type' 593feedmail will temporarily manipulate the value of `coding-system-for-write'
594to make the writing as binary. If nil, writing will be in text mode. 594to make the writing as binary. If nil, writing will be in text mode.
595On systems where there is no distinction or where it is controlled by other 595On systems where there is no distinction or where it is controlled by other
596variables or other means, this option has no effect." 596variables or other means, this option has no effect."
@@ -2016,7 +2016,6 @@ backup file names and the like)."
2016 (setq buffer-offer-save nil) 2016 (setq buffer-offer-save nil)
2017 (buffer-disable-undo blobby-buffer) 2017 (buffer-disable-undo blobby-buffer)
2018 (insert-file-contents-literally maybe-file) 2018 (insert-file-contents-literally maybe-file)
2019 (setq buffer-file-type t) ; binary
2020 (goto-char (point-min)) 2019 (goto-char (point-min))
2021 ;; if at least two line-endings with CRLF, translate the file 2020 ;; if at least two line-endings with CRLF, translate the file
2022 (if (looking-at ".*\r\n.*\r\n") 2021 (if (looking-at ".*\r\n.*\r\n")
@@ -2334,7 +2333,10 @@ mapped to mostly alphanumerics for safety."
2334 (setq filename buffer-file-name) 2333 (setq filename buffer-file-name)
2335 (setq filename (feedmail-create-queue-filename queue-directory))) 2334 (setq filename (feedmail-create-queue-filename queue-directory)))
2336 ;; make binary file on DOS/Windows 95/Windows NT, etc 2335 ;; make binary file on DOS/Windows 95/Windows NT, etc
2337 (let ((buffer-file-type feedmail-force-binary-write)) 2336 (let ((coding-system-for-write
2337 (if feedmail-force-binary-write
2338 'no-conversion
2339 coding-system-for-write)))
2338 (write-file filename)) 2340 (write-file filename))
2339 ;; convenient for moving from draft to q, for example 2341 ;; convenient for moving from draft to q, for example
2340 (if (and previous-buffer-file-name (or (not is-fqm) (not is-in-this-dir)) 2342 (if (and previous-buffer-file-name (or (not is-fqm) (not is-in-this-dir))
@@ -2571,26 +2573,27 @@ mapped to mostly alphanumerics for safety."
2571 ;; Re-insert and handle any Fcc fields (and, optionally, 2573 ;; Re-insert and handle any Fcc fields (and, optionally,
2572 ;; any Bcc). 2574 ;; any Bcc).
2573 (when fcc 2575 (when fcc
2574 (let ((old (default-value 'buffer-file-type))) 2576 (let ((coding-system-for-write
2577 (if (and (memq system-type '(ms-dos windows-nt))
2578 feedmail-force-binary-write)
2579 'no-conversion
2580 coding-system-for-write)))
2575 (unwind-protect 2581 (unwind-protect
2576 (progn 2582 (progn
2577 (setq-default buffer-file-type
2578 feedmail-force-binary-write)
2579 (insert fcc) 2583 (insert fcc)
2580 (unless feedmail-nuke-bcc-in-fcc 2584 (unless feedmail-nuke-bcc-in-fcc
2581 (if bcc-holder (insert bcc-holder)) 2585 (if bcc-holder (insert bcc-holder))
2582 (if resent-bcc-holder 2586 (if resent-bcc-holder
2583 (insert resent-bcc-holder))) 2587 (insert resent-bcc-holder)))
2584 2588
2585 (run-hooks 'feedmail-before-fcc-hook) 2589 (run-hooks 'feedmail-before-fcc-hook)
2586 2590
2587 (when feedmail-nuke-body-in-fcc 2591 (when feedmail-nuke-body-in-fcc
2588 (goto-char eoh-marker) 2592 (goto-char eoh-marker)
2589 (if (natnump feedmail-nuke-body-in-fcc) 2593 (if (natnump feedmail-nuke-body-in-fcc)
2590 (forward-line feedmail-nuke-body-in-fcc)) 2594 (forward-line feedmail-nuke-body-in-fcc))
2591 (delete-region (point) (point-max))) 2595 (delete-region (point) (point-max)))
2592 (mail-do-fcc eoh-marker)) 2596 (mail-do-fcc eoh-marker))))))
2593 (setq-default buffer-file-type old)))))
2594 ;; User bailed out of one-last-look. 2597 ;; User bailed out of one-last-look.
2595 (if feedmail-queue-runner-is-active 2598 (if feedmail-queue-runner-is-active
2596 (throw 'skip-me-q 'skip-me-q) 2599 (throw 'skip-me-q 'skip-me-q)
diff --git a/lisp/net/ange-ftp.el b/lisp/net/ange-ftp.el
index 4f7d8092891..ea318ec3250 100644
--- a/lisp/net/ange-ftp.el
+++ b/lisp/net/ange-ftp.el
@@ -3297,7 +3297,6 @@ system TYPE.")
3297 (name (ange-ftp-quote-string (nth 2 parsed))) 3297 (name (ange-ftp-quote-string (nth 2 parsed)))
3298 (temp (ange-ftp-make-tmp-name host)) 3298 (temp (ange-ftp-make-tmp-name host))
3299 (binary (ange-ftp-binary-file filename)) 3299 (binary (ange-ftp-binary-file filename))
3300 (buffer-file-type buffer-file-type)
3301 (abbr (ange-ftp-abbreviate-filename filename)) 3300 (abbr (ange-ftp-abbreviate-filename filename))
3302 (coding-system-used last-coding-system-used) 3301 (coding-system-used last-coding-system-used)
3303 size) 3302 size)
@@ -3322,10 +3321,7 @@ system TYPE.")
3322 size 3321 size
3323 (nth 1 (ange-ftp-real-insert-file-contents 3322 (nth 1 (ange-ftp-real-insert-file-contents
3324 temp visit beg end replace)) 3323 temp visit beg end replace))
3325 coding-system-used last-coding-system-used 3324 coding-system-used last-coding-system-used)
3326 ;; override autodetection of buffer file type
3327 ;; to ensure buffer is saved in DOS format
3328 buffer-file-type binary)
3329 (signal 'ftp-error 3325 (signal 'ftp-error
3330 (list 3326 (list
3331 "Opening input file:" 3327 "Opening input file:"