Commit 6e4f5731 authored by Michael Albinus's avatar Michael Albinus
Browse files

(tramp-handle-insert-file-contents): Set always the permissions of the

temporary file to "0600". In case the remote
file has no read permissions for the owner, there might be
problems otherwise.  Reported by Ole Laursen <olau@iola.dk>.
parent 272f6ebf
2010-02-18 Glenn Morris <rgm@gnu.org>
2010-02-18 Michael Albinus <michael.albinus@gmx.de>
* net/tramp.el (tramp-handle-insert-file-contents): Set always the
permissions of the temporary file to "0600". In case the remote
file has no read permissions for the owner, there might be
problems otherwise. Reported by Ole Laursen <olau@iola.dk>.
22010-02-18 Glenn Morris <rgm@gnu.org>
* emacs-lisp/authors.el (authors-renamed-files-alist):
Add entries for INSTALL.CVS.
......
......@@ -4781,12 +4781,16 @@ coding system might not be determined. This function repairs it."
tramp-temp-buffer-file-name)
(t (file-local-copy filename)))))
;; When the file is not readable for the owner, it
;; cannot be inserted, even it is redable for the group
;; or for everybody.
(set-file-modes local-copy (tramp-octal-to-decimal "0600"))
(when (and (null remote-copy)
(tramp-get-method-parameter
method 'tramp-copy-keep-tmpfile))
;; We keep the local file for performance reasons,
;; useful for "rsync".
(set-file-modes local-copy (tramp-octal-to-decimal "0600"))
(setq tramp-temp-buffer-file-name local-copy)
(put 'tramp-temp-buffer-file-name 'permanent-local t))
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment