[PATCH] Report chmod failure when --executability is on.

Matt McCutchen matt at mattmccutchen.net
Fri Jan 25 01:16:31 GMT 2008


---
 syscall.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/syscall.c b/syscall.c
index 4369c6e..39554e9 100644
--- a/syscall.c
+++ b/syscall.c
@@ -34,6 +34,7 @@ extern int am_root;
 extern int read_only;
 extern int list_only;
 extern int preserve_perms;
+extern int preserve_executability;
 
 #define RETURN_ERROR_IF(x,e) \
 	do { \
@@ -167,7 +168,7 @@ int do_chmod(const char *path, mode_t mode)
 #endif
 	} else
 		code = chmod(path, mode & CHMOD_BITS);
-	if (code != 0 && preserve_perms)
+	if (code != 0 && (preserve_perms || preserve_executability))
 	    return code;
 	return 0;
 }
-- 
1.5.4.rc3.15.g4bbc



More information about the rsync mailing list