emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Preserve permissions after backup?


From: Eli Zaretskii
Subject: Re: Preserve permissions after backup?
Date: Mon, 27 Jan 2003 08:22:14 +0200 (IST)

On Sun, 26 Jan 2003, Kai =?iso-8859-1?q?Gro=DFjohann?= wrote:

> A Tramp user is reporting that the permissions of a root-owned file
> change after he edits it with Tramp (the su method).  I'm guessing
> that's because Tramp does backup by renaming and creates a new file
> with default permissions.
> 
> Is there some machinery in Emacs which is designed to prevent things
> like this from happening?

I think that machinery is in this line of files.el:basic-save-buffer:

   (set-file-modes buffer-file-name setmodes)

[and similar lines elsewhere in basic-save-buffer's subroutines].

Perhaps Tramp sabotaged some of the code that tells Emacs there's a need 
to set file's permissions, or maybe set-file-modes itself fails under 
Tramp?




reply via email to

[Prev in Thread] Current Thread [Next in Thread]