From ccebbfa385dc3770b4b75978bcaa2b3108380412 Mon Sep 17 00:00:00 2001 From: Michael Albinus Date: Tue, 30 Jun 2009 15:30:26 +0000 Subject: [PATCH] * net/tramp.el (tramp-default-file-modes) Remove execute permissions. --- lisp/ChangeLog | 1 + lisp/net/tramp.el | 5 +++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index bf5ef0bdd7b..5f885e478b1 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -2,6 +2,7 @@ * net/tramp.el (tramp-do-copy-or-rename-file-directly): Handle also the 'rename case, when setting file modes. (Bug#3712) + (tramp-default-file-modes) Remove execute permissions. 2009-06-29 Alan Mackenzie diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el index cf1f866cb2c..517485a1d65 100644 --- a/lisp/net/tramp.el +++ b/lisp/net/tramp.el @@ -2767,8 +2767,9 @@ and gid of the corresponding user is taken. Both parameters must be integers." (defun tramp-default-file-modes (filename) "Return file modes of FILENAME as integer. If the file modes of FILENAME cannot be determined, return the -value of `default-file-modes'." - (or (file-modes filename) (default-file-modes))) +value of `default-file-modes', without execute permissions." + (or (file-modes filename) + (logand (default-file-modes) (tramp-octal-to-decimal "0666")))) (defun tramp-handle-file-directory-p (filename) "Like `file-directory-p' for Tramp files." -- 2.39.2