From de0b7af169345442852622bb337483398c583a9e Mon Sep 17 00:00:00 2001 From: Platon Pronko Date: Fri, 24 Jun 2022 17:18:19 +0200 Subject: [PATCH] Fix logic error in Tramp, setting file ownership * lisp/net/tramp.el (tramp-skeleton-write-region): Fix logic in changing file ownership. (Bug#56180) Copyright-paperwork-exempt: yes --- lisp/net/tramp.el | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el index 59a2710e00d..c6665c27924 100644 --- a/lisp/net/tramp.el +++ b/lisp/net/tramp.el @@ -3462,8 +3462,8 @@ BODY is the backend specific code." ;; `file-precious-flag' is set. (or (file-attribute-modification-time file-attr) (current-time))) - (unless (and (= (file-attribute-user-id file-attr) uid) - (= (file-attribute-group-id file-attr) gid)) + (when (and (= (file-attribute-user-id file-attr) uid) + (= (file-attribute-group-id file-attr) gid)) (setq need-chown nil)))) ;; Set the ownership. -- 2.39.2